aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorPaul Eggert2012-09-03 02:22:43 -0700
committerPaul Eggert2012-09-03 02:22:43 -0700
commit26d4541d4c0c9a71453143c17d392291c41856ff (patch)
tree2f69f4cf68d4e30f0e108ee7336f97a76441e396 /src
parentc5e28e39275c4a5a63adbe3e1e3b23a58c4a4bb8 (diff)
downloademacs-26d4541d4c0c9a71453143c17d392291c41856ff.tar.gz
emacs-26d4541d4c0c9a71453143c17d392291c41856ff.zip
Fix minor problems found by static checking.
* buffer.c (Fdelete_all_overlays): Return nil. * doc.c (Fsubstitute_command_keys): * regex.c (WEAK_ALIAS): * xdisp.c (redisplay_internal): Move initialization down, to pacify GCC 4.7.1 -Wjump-misses-init.
Diffstat (limited to 'src')
-rw-r--r--src/ChangeLog9
-rw-r--r--src/buffer.c1
-rw-r--r--src/doc.c3
-rw-r--r--src/regex.c6
-rw-r--r--src/xdisp.c3
5 files changed, 18 insertions, 4 deletions
diff --git a/src/ChangeLog b/src/ChangeLog
index 203e5dca018..43e629eb5f6 100644
--- a/src/ChangeLog
+++ b/src/ChangeLog
@@ -1,3 +1,12 @@
12012-09-03 Paul Eggert <eggert@cs.ucla.edu>
2
3 Fix minor problems found by static checking.
4 * buffer.c (Fdelete_all_overlays): Return nil.
5 * doc.c (Fsubstitute_command_keys):
6 * regex.c (WEAK_ALIAS):
7 * xdisp.c (redisplay_internal):
8 Move initialization down, to pacify GCC 4.7.1 -Wjump-misses-init.
9
12012-09-03 Martin Rudalics <rudalics@gmx.at> 102012-09-03 Martin Rudalics <rudalics@gmx.at>
2 11
3 * buffer.c (Fdelete_all_overlays): New function. 12 * buffer.c (Fdelete_all_overlays): New function.
diff --git a/src/buffer.c b/src/buffer.c
index ce6f42f136f..f4d38e50a47 100644
--- a/src/buffer.c
+++ b/src/buffer.c
@@ -4091,6 +4091,7 @@ buffer. */)
4091 } 4091 }
4092 4092
4093 delete_all_overlays (buf); 4093 delete_all_overlays (buf);
4094 return Qnil;
4094} 4095}
4095 4096
4096/* Overlay dissection functions. */ 4097/* Overlay dissection functions. */
diff --git a/src/doc.c b/src/doc.c
index 02a5b4b8143..c21935577f2 100644
--- a/src/doc.c
+++ b/src/doc.c
@@ -848,9 +848,10 @@ Otherwise, return a new string, without any text properties. */)
848 struct buffer *oldbuf; 848 struct buffer *oldbuf;
849 ptrdiff_t start_idx; 849 ptrdiff_t start_idx;
850 /* This is for computing the SHADOWS arg for describe_map_tree. */ 850 /* This is for computing the SHADOWS arg for describe_map_tree. */
851 Lisp_Object active_maps = Fcurrent_active_maps (Qnil, Qnil); 851 Lisp_Object active_maps;
852 Lisp_Object earlier_maps; 852 Lisp_Object earlier_maps;
853 853
854 active_maps = Fcurrent_active_maps (Qnil, Qnil);
854 changed = 1; 855 changed = 1;
855 strp += 2; /* skip \{ or \< */ 856 strp += 2; /* skip \{ or \< */
856 start = strp; 857 start = strp;
diff --git a/src/regex.c b/src/regex.c
index 472ef727979..28813304c8a 100644
--- a/src/regex.c
+++ b/src/regex.c
@@ -5160,11 +5160,13 @@ re_match_2_internal (struct re_pattern_buffer *bufp, const re_char *string1,
5160 { 5160 {
5161 /* 1 if this match ends in the same string (string1 or string2) 5161 /* 1 if this match ends in the same string (string1 or string2)
5162 as the best previous match. */ 5162 as the best previous match. */
5163 boolean same_str_p = (FIRST_STRING_P (match_end) 5163 boolean same_str_p;
5164 == FIRST_STRING_P (d));
5165 /* 1 if this match is the best seen so far. */ 5164 /* 1 if this match is the best seen so far. */
5166 boolean best_match_p; 5165 boolean best_match_p;
5167 5166
5167 same_str_p = (FIRST_STRING_P (match_end)
5168 == FIRST_STRING_P (d));
5169
5168 /* AIX compiler got confused when this was combined 5170 /* AIX compiler got confused when this was combined
5169 with the previous declaration. */ 5171 with the previous declaration. */
5170 if (same_str_p) 5172 if (same_str_p)
diff --git a/src/xdisp.c b/src/xdisp.c
index 86f041dea4d..81322f498ef 100644
--- a/src/xdisp.c
+++ b/src/xdisp.c
@@ -13511,9 +13511,10 @@ redisplay_internal (void)
13511 } 13511 }
13512 else if (FRAME_VISIBLE_P (sf) && !FRAME_OBSCURED_P (sf)) 13512 else if (FRAME_VISIBLE_P (sf) && !FRAME_OBSCURED_P (sf))
13513 { 13513 {
13514 Lisp_Object mini_window = FRAME_MINIBUF_WINDOW (sf); 13514 Lisp_Object mini_window;
13515 struct frame *mini_frame; 13515 struct frame *mini_frame;
13516 13516
13517 mini_window = FRAME_MINIBUF_WINDOW (sf);
13517 displayed_buffer = XBUFFER (XWINDOW (selected_window)->buffer); 13518 displayed_buffer = XBUFFER (XWINDOW (selected_window)->buffer);
13518 /* Use list_of_error, not Qerror, so that 13519 /* Use list_of_error, not Qerror, so that
13519 we catch only errors and don't run the debugger. */ 13520 we catch only errors and don't run the debugger. */