diff options
| author | Paul Eggert | 2016-01-23 01:02:00 -0800 |
|---|---|---|
| committer | Paul Eggert | 2016-01-23 01:04:09 -0800 |
| commit | c07bddd69dab6252ce1e8a283a023d693b7d7ad6 (patch) | |
| tree | b5d75d39e8e1433189fe06d129d7285e94e263af /src/xterm.c | |
| parent | 035bd8159fe5bcea15eacc8a23ab54f4bc3b6f17 (diff) | |
| download | emacs-c07bddd69dab6252ce1e8a283a023d693b7d7ad6.tar.gz emacs-c07bddd69dab6252ce1e8a283a023d693b7d7ad6.zip | |
Pacify --enable-gcc-warnings --with-cairo
Problem reported by Alexander Kuleshov in:
http://lists.gnu.org/archive/html/emacs-devel/2016-01/msg01289.html
* src/gtkutil.c (xg_get_page_setup):
Use switch rather than if-then-else.
* src/image.c (COLOR_TABLE_SUPPORT):
Define directly rather than via #define and optional later #undef.
(lookup_rgb_color) [USE_CAIRO && ENABLE_CHECKING]:
Crash when the pixel is undefined, as there is a genuine bug
here (Bug#22442).
* src/image.c (tiff_load, gif_load, svg_load_image)
(x_kill_gs_process) [USE_CAIRO]:
* src/xterm.c (x_draw_fringe_bitmap) [USE_CAIRO]:
Omit unused locals, or move them to where they’re needed.
(x_clear_area1): Now ATTRIBUTE_UNUSED.
Diffstat (limited to 'src/xterm.c')
| -rw-r--r-- | src/xterm.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/src/xterm.c b/src/xterm.c index 6a38d24c636..1f71afd7f70 100644 --- a/src/xterm.c +++ b/src/xterm.c | |||
| @@ -1313,7 +1313,6 @@ x_draw_fringe_bitmap (struct window *w, struct glyph_row *row, struct draw_fring | |||
| 1313 | { | 1313 | { |
| 1314 | struct frame *f = XFRAME (WINDOW_FRAME (w)); | 1314 | struct frame *f = XFRAME (WINDOW_FRAME (w)); |
| 1315 | Display *display = FRAME_X_DISPLAY (f); | 1315 | Display *display = FRAME_X_DISPLAY (f); |
| 1316 | Window window = FRAME_X_WINDOW (f); | ||
| 1317 | GC gc = f->output_data.x->normal_gc; | 1316 | GC gc = f->output_data.x->normal_gc; |
| 1318 | struct face *face = p->face; | 1317 | struct face *face = p->face; |
| 1319 | 1318 | ||
| @@ -1356,6 +1355,7 @@ x_draw_fringe_bitmap (struct window *w, struct glyph_row *row, struct draw_fring | |||
| 1356 | #else /* not USE_CAIRO */ | 1355 | #else /* not USE_CAIRO */ |
| 1357 | if (p->which) | 1356 | if (p->which) |
| 1358 | { | 1357 | { |
| 1358 | Window window = FRAME_X_WINDOW (f); | ||
| 1359 | char *bits; | 1359 | char *bits; |
| 1360 | Pixmap pixmap, clipmask = (Pixmap) 0; | 1360 | Pixmap pixmap, clipmask = (Pixmap) 0; |
| 1361 | int depth = DefaultDepthOfScreen (FRAME_X_SCREEN (f)); | 1361 | int depth = DefaultDepthOfScreen (FRAME_X_SCREEN (f)); |
| @@ -3758,7 +3758,7 @@ x_delete_glyphs (struct frame *f, register int n) | |||
| 3758 | /* Like XClearArea, but check that WIDTH and HEIGHT are reasonable. | 3758 | /* Like XClearArea, but check that WIDTH and HEIGHT are reasonable. |
| 3759 | If they are <= 0, this is probably an error. */ | 3759 | If they are <= 0, this is probably an error. */ |
| 3760 | 3760 | ||
| 3761 | static void | 3761 | static ATTRIBUTE_UNUSED void |
| 3762 | x_clear_area1 (Display *dpy, Window window, | 3762 | x_clear_area1 (Display *dpy, Window window, |
| 3763 | int x, int y, int width, int height, int exposures) | 3763 | int x, int y, int width, int height, int exposures) |
| 3764 | { | 3764 | { |
| @@ -3766,7 +3766,6 @@ x_clear_area1 (Display *dpy, Window window, | |||
| 3766 | XClearArea (dpy, window, x, y, width, height, exposures); | 3766 | XClearArea (dpy, window, x, y, width, height, exposures); |
| 3767 | } | 3767 | } |
| 3768 | 3768 | ||
| 3769 | |||
| 3770 | void | 3769 | void |
| 3771 | x_clear_area (struct frame *f, int x, int y, int width, int height) | 3770 | x_clear_area (struct frame *f, int x, int y, int width, int height) |
| 3772 | { | 3771 | { |