aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorPaul Eggert2013-12-14 20:20:53 -0800
committerPaul Eggert2013-12-14 20:20:53 -0800
commitb4dd49e0faee3ff97b544cab2ef82898310c8999 (patch)
treef2274915eb78730bf3abe09480d313fc16f8b731 /src
parentf629af5493b01170f0fc9c26d8a51c928f4ea711 (diff)
downloademacs-b4dd49e0faee3ff97b544cab2ef82898310c8999.tar.gz
emacs-b4dd49e0faee3ff97b544cab2ef82898310c8999.zip
Use bool for boolean (GLYPH_DEBUG case).
* xdisp.c (trace_redisplay_p) [GLYPH_DEBUG]: Use bool for boolean. * dispextern.h (IF_DEBUG): Properly parenthesize and convert to void. Args must now be expressions; all callers changed.
Diffstat (limited to 'src')
-rw-r--r--src/ChangeLog3
-rw-r--r--src/dispextern.h2
-rw-r--r--src/gnutls.c9
-rw-r--r--src/xdisp.c8
4 files changed, 11 insertions, 11 deletions
diff --git a/src/ChangeLog b/src/ChangeLog
index a063d2d51d6..ebf715e9374 100644
--- a/src/ChangeLog
+++ b/src/ChangeLog
@@ -77,6 +77,7 @@
77 (sync_frame_with_window_matrix_rows, try_window_id) 77 (sync_frame_with_window_matrix_rows, try_window_id)
78 (display_menu_bar, display_tty_menu_item, display_mode_line) 78 (display_menu_bar, display_tty_menu_item, display_mode_line)
79 (coords_in_mouse_face_p, cursor_in_mouse_face_p): 79 (coords_in_mouse_face_p, cursor_in_mouse_face_p):
80 * xdisp.c (trace_redisplay_p) [GLYPH_DEBUG]:
80 * xmenu.c (xmenu_show): 81 * xmenu.c (xmenu_show):
81 * xterm.c (use_xim, x_term_init): 82 * xterm.c (use_xim, x_term_init):
82 * xterm.h (XSync, GTK_CHECK_VERSION, use_xim, SET_SCROLL_BAR_X_WIDGET) 83 * xterm.h (XSync, GTK_CHECK_VERSION, use_xim, SET_SCROLL_BAR_X_WIDGET)
@@ -118,6 +119,8 @@
118 * dispextern.h (TRACE, PREPARE_FACE_FOR_DISPLAY): 119 * dispextern.h (TRACE, PREPARE_FACE_FOR_DISPLAY):
119 * interval.h (RESET_INTERVAL, COPY_INTERVAL_CACHE, MERGE_INTERVAL_CACHE) 120 * interval.h (RESET_INTERVAL, COPY_INTERVAL_CACHE, MERGE_INTERVAL_CACHE)
120 Surround statement macro with proper 'do { ... } while (false)' brackets. 121 Surround statement macro with proper 'do { ... } while (false)' brackets.
122 * dispextern.h (IF_DEBUG): Properly parenthesize and convert to void.
123 Args must now be expressions; all callers changed.
121 (SET_MATRIX_ROW_ENABLED_P): Assume 2nd arg is bool. 124 (SET_MATRIX_ROW_ENABLED_P): Assume 2nd arg is bool.
122 (PRODUCE_GLYPHS): Simplify use of boolean. 125 (PRODUCE_GLYPHS): Simplify use of boolean.
123 * fileio.c (Fcopy_file): 126 * fileio.c (Fcopy_file):
diff --git a/src/dispextern.h b/src/dispextern.h
index ded11e58dfb..d3ee2472dc6 100644
--- a/src/dispextern.h
+++ b/src/dispextern.h
@@ -139,7 +139,7 @@ enum window_part
139/* Macros to include code only if GLYPH_DEBUG is defined. */ 139/* Macros to include code only if GLYPH_DEBUG is defined. */
140 140
141#ifdef GLYPH_DEBUG 141#ifdef GLYPH_DEBUG
142#define IF_DEBUG(X) (X) 142#define IF_DEBUG(X) ((void) (X))
143#else 143#else
144#define IF_DEBUG(X) ((void) 0) 144#define IF_DEBUG(X) ((void) 0)
145#endif 145#endif
diff --git a/src/gnutls.c b/src/gnutls.c
index a14d3ef31c5..dd9f30f4de9 100644
--- a/src/gnutls.c
+++ b/src/gnutls.c
@@ -825,8 +825,7 @@ one trustfile (usually a CA bundle). */)
825 verify_error = Fplist_get (proplist, QCgnutls_bootprop_verify_error); 825 verify_error = Fplist_get (proplist, QCgnutls_bootprop_verify_error);
826 prime_bits = Fplist_get (proplist, QCgnutls_bootprop_min_prime_bits); 826 prime_bits = Fplist_get (proplist, QCgnutls_bootprop_min_prime_bits);
827 827
828 if (!Flistp (verify_error)) 828 CHECK_LIST_CONS (verify_error, verify_error);
829 error ("gnutls-boot: invalid :verify_error parameter (not a list)");
830 829
831 if (!STRINGP (hostname)) 830 if (!STRINGP (hostname))
832 error ("gnutls-boot: invalid :hostname parameter (not a string)"); 831 error ("gnutls-boot: invalid :hostname parameter (not a string)");
@@ -1071,8 +1070,7 @@ one trustfile (usually a CA bundle). */)
1071 1070
1072 if (peer_verification != 0) 1071 if (peer_verification != 0)
1073 { 1072 {
1074 if (EQ (verify_error, Qt) 1073 if (!NILP (Fmember (QCgnutls_bootprop_trustfiles, verify_error)))
1075 || !NILP (Fmember (QCgnutls_bootprop_trustfiles, verify_error)))
1076 { 1074 {
1077 emacs_gnutls_deinit (proc); 1075 emacs_gnutls_deinit (proc);
1078 error ("Certificate validation failed %s, verification code %d", 1076 error ("Certificate validation failed %s, verification code %d",
@@ -1121,8 +1119,7 @@ one trustfile (usually a CA bundle). */)
1121 1119
1122 if (!fn_gnutls_x509_crt_check_hostname (gnutls_verify_cert, c_hostname)) 1120 if (!fn_gnutls_x509_crt_check_hostname (gnutls_verify_cert, c_hostname))
1123 { 1121 {
1124 if (EQ (verify_error, Qt) 1122 if (!NILP (Fmember (QCgnutls_bootprop_hostname, verify_error)))
1125 || !NILP (Fmember (QCgnutls_bootprop_hostname, verify_error)))
1126 { 1123 {
1127 fn_gnutls_x509_crt_deinit (gnutls_verify_cert); 1124 fn_gnutls_x509_crt_deinit (gnutls_verify_cert);
1128 emacs_gnutls_deinit (proc); 1125 emacs_gnutls_deinit (proc);
diff --git a/src/xdisp.c b/src/xdisp.c
index 97fa0ce5fe7..b5274b53229 100644
--- a/src/xdisp.c
+++ b/src/xdisp.c
@@ -662,7 +662,7 @@ bset_update_mode_line (struct buffer *b)
662/* Non-zero means print traces of redisplay if compiled with 662/* Non-zero means print traces of redisplay if compiled with
663 GLYPH_DEBUG defined. */ 663 GLYPH_DEBUG defined. */
664 664
665int trace_redisplay_p; 665bool trace_redisplay_p;
666 666
667#endif /* GLYPH_DEBUG */ 667#endif /* GLYPH_DEBUG */
668 668
@@ -17723,7 +17723,7 @@ try_window_id (struct window *w)
17723 = run.current_y = run.desired_y = run.height = 0; 17723 = run.current_y = run.desired_y = run.height = 0;
17724 first_unchanged_at_end_row = NULL; 17724 first_unchanged_at_end_row = NULL;
17725 } 17725 }
17726 IF_DEBUG (debug_dvpos = dvpos; debug_dy = dy); 17726 IF_DEBUG ((debug_dvpos = dvpos, debug_dy = dy));
17727 17727
17728 17728
17729 /* Find the cursor if not already found. We have to decide whether 17729 /* Find the cursor if not already found. We have to decide whether
@@ -18019,8 +18019,8 @@ try_window_id (struct window *w)
18019 else 18019 else
18020 emacs_abort (); 18020 emacs_abort ();
18021 18021
18022 IF_DEBUG (debug_end_pos = w->window_end_pos; 18022 IF_DEBUG ((debug_end_pos = w->window_end_pos,
18023 debug_end_vpos = w->window_end_vpos); 18023 debug_end_vpos = w->window_end_vpos));
18024 18024
18025 /* Record that display has not been completed. */ 18025 /* Record that display has not been completed. */
18026 w->window_end_valid = 0; 18026 w->window_end_valid = 0;