From: Noam Postavsky Date: Fri, 10 Feb 2017 20:33:05 +0000 (-0500) Subject: Fix warnings in debug tracing code X-Git-Tag: emacs-26.0.90~848^2~3 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=26187a38a17734d313c1294f47f95c4926d7b6ef;p=emacs.git Fix warnings in debug tracing code * src/xdisp.c (dump_glyph, dump_glyph_string): * src/xfaces.c (dump_realized_face): Cast arguments or adjust format specifiers to match signedness. --- diff --git a/src/xdisp.c b/src/xdisp.c index 6cb5b4e0562..e59934d2d5a 100644 --- a/src/xdisp.c +++ b/src/xdisp.c @@ -18972,7 +18972,7 @@ dump_glyph (struct glyph_row *row, struct glyph *glyph, int area) glyph->pixel_width, glyph->u.ch, (glyph->u.ch < 0x80 && glyph->u.ch >= ' ' - ? glyph->u.ch + ? (int) glyph->u.ch : '.'), glyph->face_id, glyph->left_box_line_p, @@ -18993,7 +18993,7 @@ dump_glyph (struct glyph_row *row, struct glyph *glyph, int area) ? '0' : '-'))), glyph->pixel_width, - 0, + 0u, ' ', glyph->face_id, glyph->left_box_line_p, @@ -19014,7 +19014,7 @@ dump_glyph (struct glyph_row *row, struct glyph *glyph, int area) ? '0' : '-'))), glyph->pixel_width, - glyph->u.img_id, + (unsigned int) glyph->u.img_id, '.', glyph->face_id, glyph->left_box_line_p, @@ -19035,7 +19035,7 @@ dump_glyph (struct glyph_row *row, struct glyph *glyph, int area) ? '0' : '-'))), glyph->pixel_width, - glyph->u.cmp.id); + (unsigned int) glyph->u.cmp.id); if (glyph->u.cmp.automatic) fprintf (stderr, "[%d-%d]", @@ -24616,7 +24616,7 @@ dump_glyph_string (struct glyph_string *s) fprintf (stderr, " x, y, w, h = %d, %d, %d, %d\n", s->x, s->y, s->width, s->height); fprintf (stderr, " ybase = %d\n", s->ybase); - fprintf (stderr, " hl = %d\n", s->hl); + fprintf (stderr, " hl = %u\n", s->hl); fprintf (stderr, " left overhang = %d, right = %d\n", s->left_overhang, s->right_overhang); fprintf (stderr, " nchars = %d\n", s->nchars); diff --git a/src/xfaces.c b/src/xfaces.c index 830106d64c0..b5dbb53ca20 100644 --- a/src/xfaces.c +++ b/src/xfaces.c @@ -6251,7 +6251,7 @@ dump_realized_face (struct face *face) fprintf (stderr, "underline: %d (%s)\n", face->underline_p, SDATA (Fsymbol_name (face->lface[LFACE_UNDERLINE_INDEX]))); - fprintf (stderr, "hash: %d\n", face->hash); + fprintf (stderr, "hash: %u\n", face->hash); }