From: Ivan Maidanski Date: Fri, 21 Jul 2017 15:17:06 +0000 (+0300) Subject: Eliminate CSA warning about incorrect cast applied to HBLK_OBJS X-Git-Tag: v8.0.0~628 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=3acde978398b145b1e2d8900de634ca9d75ada18;p=gc Eliminate CSA warning about incorrect cast applied to HBLK_OBJS HBLK_OBJS() expects the argument value and has the result value of size_t type. * reclaim.c (GC_print_block_descr): Cast result of HBLK_OBJS() to unsigned int instead of casting its argument. --- diff --git a/reclaim.c b/reclaim.c index d3070054..2361406e 100644 --- a/reclaim.c +++ b/reclaim.c @@ -538,7 +538,7 @@ STATIC void GC_print_block_descr(struct hblk *h, size_t bytes = hhdr -> hb_sz; struct Print_stats *ps; unsigned n_marks = GC_n_set_marks(hhdr); - unsigned n_objs = HBLK_OBJS((unsigned)bytes); + unsigned n_objs = (unsigned)HBLK_OBJS(bytes); if (0 == n_objs) n_objs = 1; if (hhdr -> hb_n_marks != n_marks) {