]> git.eshelyaron.com Git - emacs.git/commitdiff
xdisp.c (BUILD_COMPOSITE_GLYPH_STRING): Mark variables that
authorPaul Eggert <eggert@cs.ucla.edu>
Sun, 6 Mar 2011 22:04:59 +0000 (14:04 -0800)
committerPaul Eggert <eggert@cs.ucla.edu>
Sun, 6 Mar 2011 22:04:59 +0000 (14:04 -0800)
gcc -Wuninitialized cannot deduce are never used uninitialized.

src/ChangeLog
src/xdisp.c

index 23bf646f7422fc3300ddce22c4b630f7ae58345c..ff8c5fd027d8bbfd97b86984a3ed8440a9b6190e 100644 (file)
@@ -4,8 +4,9 @@
        Add a FIXME comment, since the code still doesn't look right.
        (Fcurrent_bidi_paragraph_direction): Simplify slightly; this
        avoids a gcc -Wuninitialized diagnostic.
-       (display_line): Mark variables that gcc -Wuninitialized cannot
-       deduce are never used uninitialized.
+       (display_line, BUILD_COMPOSITE_GLYPH_STRING): Mark variables that
+       gcc -Wuninitialized cannot deduce are never used uninitialized.
+
        * lisp.h (IF_LINT): New macro, copied from ../lib-src/emacsclient.c
        which in turn is copied from coreutils.
 
index 180c65d18edf4a7ce23bd0b18c1fcb52644181b5..0f8fd3d0477ad04986448d4180d99215dbd574ca 100644 (file)
@@ -21089,7 +21089,7 @@ compute_overhangs_and_x (struct glyph_string *s, int x, int backward_p)
     int cmp_id = (row)->glyphs[area][START].u.cmp.id;                      \
     struct composition *cmp = composition_table[cmp_id];                   \
     XChar2b *char2b;                                                       \
-    struct glyph_string *first_s;                                          \
+    struct glyph_string *first_s IF_LINT (= NULL);                         \
     int n;                                                                 \
                                                                            \
     char2b = (XChar2b *) alloca ((sizeof *char2b) * cmp->glyph_len);       \