From: Paul Eggert Date: Sun, 6 Mar 2011 22:04:59 +0000 (-0800) Subject: xdisp.c (BUILD_COMPOSITE_GLYPH_STRING): Mark variables that X-Git-Tag: emacs-pretest-24.0.90~104^2~275^2~605^2^2~80 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=70739cbeb98fae41f27fc2e4fc34670c8ec39bb7;p=emacs.git xdisp.c (BUILD_COMPOSITE_GLYPH_STRING): Mark variables that gcc -Wuninitialized cannot deduce are never used uninitialized. --- diff --git a/src/ChangeLog b/src/ChangeLog index 23bf646f742..ff8c5fd027d 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -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. diff --git a/src/xdisp.c b/src/xdisp.c index 180c65d18ed..0f8fd3d0477 100644 --- a/src/xdisp.c +++ b/src/xdisp.c @@ -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); \