[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Emacs-diffs] trunk r116880: src/*.c: Silence a few warnings about unuse
From: |
Juanma Barranquero |
Subject: |
[Emacs-diffs] trunk r116880: src/*.c: Silence a few warnings about unused vars and functions. |
Date: |
Wed, 26 Mar 2014 10:22:19 +0000 |
User-agent: |
Bazaar (2.6b2) |
------------------------------------------------------------
revno: 116880
revision-id: address@hidden
parent: address@hidden
committer: Juanma Barranquero <address@hidden>
branch nick: trunk
timestamp: Wed 2014-03-26 11:21:55 +0100
message:
src/*.c: Silence a few warnings about unused vars and functions.
* src/image.c (x_bitmap_height, x_bitmap_width) [HAVE_X_WINDOWS]:
* src/sysdep.c (reset_sigio) [!DOS_NT]: Declare conditionally.
* src/keyboard.c (read_decoded_event_from_main_queue): #ifdef out
variables on Windows.
* src/w32.c (unsetenv): Remove unused var `retval'.
(emacs_gnutls_pull): Remove unused vars `fdset' and `timeout'.
* src/w32fns.c (Ffile_system_info): Use parenthesis in and/or expression.
* src/w32notify.c (watch_worker): Remove unnecesary var sleep_result.
(start_watching): Remove unused var `thr'.
* src/w32proc.c (sys_spawnve): Comment out unused vars `first', `last'.
(find_child_console): Remove unnecesary var `thread_id'.
* src/w32term.c (w32_read_socket): Comment out unused vars `row', `columns'.
(x_focus_frame): #ifdef 0 unused variable `dpyinfo'.
modified:
src/ChangeLog changelog-20091113204419-o5vbwnq5f7feedwu-1438
src/image.c image.c-20091113204419-o5vbwnq5f7feedwu-2969
src/keyboard.c keyboard.c-20091113204419-o5vbwnq5f7feedwu-449
src/sysdep.c sysdep.c-20091113204419-o5vbwnq5f7feedwu-448
src/w32.c w32.c-20091113204419-o5vbwnq5f7feedwu-808
src/w32fns.c w32fns.c-20091113204419-o5vbwnq5f7feedwu-945
src/w32notify.c w32notify.c-20121007123611-xyh65j2ka2vm684f-1
src/w32proc.c w32proc.c-20091113204419-o5vbwnq5f7feedwu-814
src/w32term.c w32term.c-20091113204419-o5vbwnq5f7feedwu-950
=== modified file 'src/ChangeLog'
--- a/src/ChangeLog 2014-03-26 01:24:01 +0000
+++ b/src/ChangeLog 2014-03-26 10:21:55 +0000
@@ -1,3 +1,25 @@
+2014-03-26 Juanma Barranquero <address@hidden>
+
+ * image.c (x_bitmap_height, x_bitmap_width) [HAVE_X_WINDOWS]:
+ * sysdep.c (reset_sigio) [!DOS_NT]: Declare conditionally.
+
+ * keyboard.c (read_decoded_event_from_main_queue): #ifdef out
+ variables on Windows.
+
+ * w32fns.c (Ffile_system_info): Use parenthesis in and/or expression.
+
+ * w32.c (unsetenv): Remove unused var `retval'.
+ (emacs_gnutls_pull): Remove unused vars `fdset' and `timeout'.
+
+ * w32notify.c (watch_worker): Remove unnecesary var sleep_result.
+ (start_watching): Remove unused var `thr'.
+
+ * w32proc.c (sys_spawnve): Comment out unused vars `first', `last'.
+ (find_child_console): Remove unnecesary var `thread_id'.
+
+ * w32term.c (w32_read_socket): Comment out unused vars `row', `columns'.
+ (x_focus_frame): #ifdef 0 unused variable `dpyinfo'.
+
2014-03-26 Glenn Morris <address@hidden>
* filelock.c (Flock_buffer): Doc tweak.
=== modified file 'src/image.c'
--- a/src/image.c 2014-02-19 17:26:14 +0000
+++ b/src/image.c 2014-03-26 10:21:55 +0000
@@ -160,6 +160,7 @@
/* Functions to access the contents of a bitmap, given an id. */
+#ifdef HAVE_X_WINDOWS
static int
x_bitmap_height (struct frame *f, ptrdiff_t id)
{
@@ -171,6 +172,7 @@
{
return FRAME_DISPLAY_INFO (f)->bitmaps[id - 1].width;
}
+#endif
#if defined (HAVE_X_WINDOWS) || defined (HAVE_NTGUI)
ptrdiff_t
=== modified file 'src/keyboard.c'
--- a/src/keyboard.c 2014-03-25 14:43:26 +0000
+++ b/src/keyboard.c 2014-03-26 10:21:55 +0000
@@ -2299,8 +2299,10 @@
bool *used_mouse_menu)
{
#define MAX_ENCODED_BYTES 16
+#ifndef WINDOWSNT
Lisp_Object events[MAX_ENCODED_BYTES];
int n = 0;
+#endif
while (true)
{
Lisp_Object nextevt
=== modified file 'src/sysdep.c'
--- a/src/sysdep.c 2014-03-25 14:43:26 +0000
+++ b/src/sysdep.c 2014-03-26 10:21:55 +0000
@@ -603,6 +603,7 @@
#endif
}
+#ifndef DOS_NT
static void
reset_sigio (int fd)
{
@@ -610,6 +611,7 @@
fcntl (fd, F_SETFL, old_fcntl_flags[fd]);
#endif
}
+#endif
void
request_sigio (void)
=== modified file 'src/w32.c'
--- a/src/w32.c 2014-03-25 16:00:37 +0000
+++ b/src/w32.c 2014-03-26 10:21:55 +0000
@@ -2413,7 +2413,6 @@
{
char *var;
size_t name_len;
- int retval;
if (name == NULL || *name == '\0' || strchr (name, '=') != NULL)
{
@@ -9261,8 +9260,6 @@
emacs_gnutls_pull (gnutls_transport_ptr_t p, void* buf, size_t sz)
{
int n, err;
- SELECT_TYPE fdset;
- struct timespec timeout;
struct Lisp_Process *process = (struct Lisp_Process *)p;
int fd = process->infd;
=== modified file 'src/w32fns.c'
--- a/src/w32fns.c 2014-03-23 18:11:18 +0000
+++ b/src/w32fns.c 2014-03-26 10:21:55 +0000
@@ -7528,8 +7528,8 @@
(char *, PULARGE_INTEGER, PULARGE_INTEGER, PULARGE_INTEGER)
= GetProcAddress (hKernel, "GetDiskFreeSpaceExA");
bool have_pfn_GetDiskFreeSpaceEx =
- (w32_unicode_filenames && pfn_GetDiskFreeSpaceExW
- || !w32_unicode_filenames && pfn_GetDiskFreeSpaceExA);
+ ((w32_unicode_filenames && pfn_GetDiskFreeSpaceExW)
+ || (!w32_unicode_filenames && pfn_GetDiskFreeSpaceExA));
/* On Windows, we may need to specify the root directory of the
volume holding FILENAME. */
=== modified file 'src/w32notify.c'
--- a/src/w32notify.c 2014-01-01 07:43:34 +0000
+++ b/src/w32notify.c 2014-03-26 10:21:55 +0000
@@ -247,7 +247,6 @@
do {
BOOL status;
- DWORD sleep_result;
DWORD bytes_ret = 0;
if (dirwatch->dir)
@@ -275,7 +274,7 @@
/* Sleep indefinitely until awoken by the I/O completion, which
could be either a change notification or a cancellation of the
watch. */
- sleep_result = SleepEx (INFINITE, TRUE);
+ SleepEx (INFINITE, TRUE);
} while (!dirwatch->terminate);
return 0;
@@ -287,7 +286,6 @@
start_watching (const char *file, HANDLE hdir, BOOL subdirs, DWORD flags)
{
struct notification *dirwatch = xzalloc (sizeof (struct notification));
- HANDLE thr;
dirwatch->signature = DIRWATCH_SIGNATURE;
dirwatch->buf = xmalloc (16384);
=== modified file 'src/w32proc.c'
--- a/src/w32proc.c 2014-02-13 20:54:07 +0000
+++ b/src/w32proc.c 2014-03-26 10:21:55 +0000
@@ -1772,12 +1772,12 @@
if (need_quotes)
{
int escape_char_run = 0;
- char * first;
- char * last;
+ /* char * first; */
+ /* char * last; */
p = *targ;
- first = p;
- last = p + strlen (p) - 1;
+ /* first = p; */
+ /* last = p + strlen (p) - 1; */
*parg++ = '"';
#if 0
/* This version does not escape quotes if they occur at the
@@ -2249,10 +2249,9 @@
find_child_console (HWND hwnd, LPARAM arg)
{
child_process * cp = (child_process *) arg;
- DWORD thread_id;
DWORD process_id;
- thread_id = GetWindowThreadProcessId (hwnd, &process_id);
+ GetWindowThreadProcessId (hwnd, &process_id);
if (process_id == cp->procinfo.dwProcessId)
{
char window_class[32];
=== modified file 'src/w32term.c'
--- a/src/w32term.c 2014-03-21 10:14:10 +0000
+++ b/src/w32term.c 2014-03-26 10:21:55 +0000
@@ -4752,8 +4752,8 @@
width = rect.right - rect.left;
text_width = FRAME_PIXEL_TO_TEXT_WIDTH (f, width);
text_height = FRAME_PIXEL_TO_TEXT_HEIGHT (f, height);
- rows = FRAME_PIXEL_HEIGHT_TO_TEXT_LINES (f, height);
- columns = FRAME_PIXEL_WIDTH_TO_TEXT_COLS (f, width);
+ /* rows = FRAME_PIXEL_HEIGHT_TO_TEXT_LINES (f, height); */
+ /* columns = FRAME_PIXEL_WIDTH_TO_TEXT_COLS (f, width); */
/* TODO: Clip size to the screen dimensions. */
@@ -5794,7 +5794,9 @@
void
x_focus_frame (struct frame *f)
{
+#if 0
struct w32_display_info *dpyinfo = &one_w32_display_info;
+#endif
/* Give input focus to frame. */
block_input ();
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Emacs-diffs] trunk r116880: src/*.c: Silence a few warnings about unused vars and functions.,
Juanma Barranquero <=