Error: CPPCHECK_WARNING (CWE-476): [#def1] pango-1.56.3/pango/pangocairo-font.c:68: warning[nullPointer]: Possible null pointer dereference: cf_priv # 66| cairo_font_face_t *font_face; # 67| # 68|-> if (G_LIKELY (cf_priv->scaled_font)) # 69| return cf_priv->scaled_font; # 70| Error: CPPCHECK_WARNING (CWE-476): [#def2] pango-1.56.3/pango/pangocairo-font.c:245: warning[nullPointer]: Possible null pointer dereference: cf_priv # 243| const char *sample_str = pango_language_get_sample_string (language); # 244| # 245|-> tmp_list = cf_priv->metrics_by_lang; # 246| while (tmp_list) # 247| { Error: CPPCHECK_WARNING (CWE-476): [#def3] pango-1.56.3/pango/pangocairo-font.c:656: warning[nullPointer]: Possible null pointer dereference: cf_priv # 654| cairo_font_options_t *options) # 655| { # 656|-> if (cf_priv->scaled_font) # 657| cairo_scaled_font_get_font_options (cf_priv->scaled_font, options); # 658| else if (cf_priv->data) Error: CPPCHECK_WARNING (CWE-476): [#def4] pango-1.56.3/pango/pangofc-fontmap.c:834: warning[nullPointerOutOfMemory]: If memory allocation fails, then there is a possible null pointer dereference: copy # 832| # 833| copy = malloc (sizeof (FcFontSet)); # 834|-> copy->sfont = copy->nfont = fontset->nfont; # 835| copy->fonts = malloc (sizeof (FcPattern *) * copy->nfont); # 836| memcpy (copy->fonts, fontset->fonts, sizeof (FcPattern *) * copy->nfont); Error: CPPCHECK_WARNING (CWE-476): [#def5] pango-1.56.3/pango/pangofc-fontmap.c:835: warning[nullPointerOutOfMemory]: If memory allocation fails, then there is a possible null pointer dereference: copy # 833| copy = malloc (sizeof (FcFontSet)); # 834| copy->sfont = copy->nfont = fontset->nfont; # 835|-> copy->fonts = malloc (sizeof (FcPattern *) * copy->nfont); # 836| memcpy (copy->fonts, fontset->fonts, sizeof (FcPattern *) * copy->nfont); # 837| for (i = 0; i < copy->nfont; i++) Error: CPPCHECK_WARNING (CWE-476): [#def6] pango-1.56.3/pango/pangofc-fontmap.c:836: warning[nullPointerOutOfMemory]: If memory allocation fails, then there is a possible null pointer dereference: copy # 834| copy->sfont = copy->nfont = fontset->nfont; # 835| copy->fonts = malloc (sizeof (FcPattern *) * copy->nfont); # 836|-> memcpy (copy->fonts, fontset->fonts, sizeof (FcPattern *) * copy->nfont); # 837| for (i = 0; i < copy->nfont; i++) # 838| FcPatternReference (copy->fonts[i]); Error: CPPCHECK_WARNING (CWE-476): [#def7] pango-1.56.3/pango/pangofc-fontmap.c:837: warning[nullPointerOutOfMemory]: If memory allocation fails, then there is a possible null pointer dereference: copy # 835| copy->fonts = malloc (sizeof (FcPattern *) * copy->nfont); # 836| memcpy (copy->fonts, fontset->fonts, sizeof (FcPattern *) * copy->nfont); # 837|-> for (i = 0; i < copy->nfont; i++) # 838| FcPatternReference (copy->fonts[i]); # 839| Error: CPPCHECK_WARNING (CWE-476): [#def8] pango-1.56.3/pango/pangofc-fontmap.c:838: warning[nullPointerOutOfMemory]: If memory allocation fails, then there is a possible null pointer dereference: copy # 836| memcpy (copy->fonts, fontset->fonts, sizeof (FcPattern *) * copy->nfont); # 837| for (i = 0; i < copy->nfont; i++) # 838|-> FcPatternReference (copy->fonts[i]); # 839| # 840| return copy; Error: GCC_ANALYZER_WARNING (CWE-476): [#def9] pango-1.56.3/redhat-linux-build/../pango/fonts.c:2056:10: warning[-Wanalyzer-null-dereference]: dereference of NULL ‘0’ pango-1.56.3/redhat-linux-build/../pango/fonts.c:2052:1: enter_function: entry to ‘pango_font_default_get_face’ pango-1.56.3/redhat-linux-build/../pango/fonts.c:2054:23: call_function: calling ‘pango_font_get_font_map’ from ‘pango_font_default_get_face’ pango-1.56.3/redhat-linux-build/../pango/fonts.c:2054:23: return_function: returning to ‘pango_font_default_get_face’ from ‘pango_font_get_font_map’ pango-1.56.3/redhat-linux-build/../pango/fonts.c:2056:10: danger: dereference of NULL ‘pango_font_get_font_map(font)’ # 2054| PangoFontMap *map = pango_font_get_font_map (font); # 2055| # 2056|-> return PANGO_FONT_MAP_GET_CLASS (map)->get_face (map,font); # 2057| } # 2058| Error: GCC_ANALYZER_WARNING (CWE-688): [#def10] pango-1.56.3/redhat-linux-build/../pango/fonts.c:2878:15: warning[-Wanalyzer-null-argument]: use of NULL where non-null expected pango-1.56.3/redhat-linux-build/../pango/fonts.c:2876:19: branch_true: following ‘true’ branch... pango-1.56.3/redhat-linux-build/../pango/fonts.c:2878:65: branch_true: ...to here pango-1.56.3/redhat-linux-build/../pango/fonts.c:2878:15: danger: argument 2 (‘pango_font_face_get_face_name(*<unknown>)’) NULL where non-null expected # 2876| for (i = 0; i < n_faces; i++) # 2877| { # 2878|-> if (strcmp (name, pango_font_face_get_face_name (faces[i])) == 0) # 2879| { # 2880| face = faces[i]; Error: GCC_ANALYZER_WARNING (CWE-476): [#def11] pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2143:15: warning[-Wanalyzer-null-dereference]: dereference of NULL ‘0’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2328:1: enter_function: entry to ‘pango_attr_list_splice’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2337:3: branch_true: following ‘true’ branch (when ‘list’ is non-NULL)... pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2338:3: branch_true: ...to here pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2338:3: branch_true: following ‘true’ branch (when ‘other’ is non-NULL)... pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2339:3: branch_true: ...to here pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2339:3: branch_true: following ‘true’ branch (when ‘pos >= 0’)... pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2340:3: branch_true: ...to here pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2340:3: branch_true: following ‘true’ branch (when ‘len >= 0’)... pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2342:3: branch_true: ...to here pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2374:6: branch_false: following ‘false’ branch... pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2377:43: branch_true: following ‘true’ branch... pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2379:52: branch_true: ...to here pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2379:30: call_function: calling ‘pango_attribute_copy’ from ‘pango_attr_list_splice’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2379:30: return_function: returning to ‘pango_attr_list_splice’ from ‘pango_attribute_copy’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2394:7: call_function: calling ‘pango_attr_list_change’ from ‘pango_attr_list_splice’ # 2141| PangoAttribute *end_attr = pango_attribute_copy (tmp_attr); # 2142| # 2143|-> end_attr->start_index = end_index; # 2144| pango_attr_list_insert (list, end_attr); # 2145| } Error: GCC_ANALYZER_WARNING (CWE-476): [#def12] pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2382:31: warning[-Wanalyzer-null-dereference]: dereference of NULL ‘0’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2328:1: enter_function: entry to ‘pango_attr_list_splice’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2337:3: branch_true: following ‘true’ branch (when ‘list’ is non-NULL)... pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2338:3: branch_true: ...to here pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2338:3: branch_true: following ‘true’ branch (when ‘other’ is non-NULL)... pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2339:3: branch_true: ...to here pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2339:3: branch_true: following ‘true’ branch (when ‘pos >= 0’)... pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2340:3: branch_true: ...to here pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2340:3: branch_true: following ‘true’ branch (when ‘len >= 0’)... pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2342:3: branch_true: ...to here pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2374:6: branch_false: following ‘false’ branch... pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2377:43: branch_true: following ‘true’ branch... pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2379:52: branch_true: ...to here pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2379:30: call_function: calling ‘pango_attribute_copy’ from ‘pango_attr_list_splice’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2379:30: return_function: returning to ‘pango_attr_list_splice’ from ‘pango_attribute_copy’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2380:10: branch_true: following ‘true’ branch (when ‘ulen != 0’)... pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2382:31: branch_true: ...to here pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2382:31: danger: dereference of NULL ‘pango_attribute_copy(*<unknown>)’ # 2380| if (ulen > 0) # 2381| { # 2382|-> attr->start_index = MIN (CLAMP_ADD (attr->start_index, upos), end); # 2383| attr->end_index = MIN (CLAMP_ADD (attr->end_index, upos), end); # 2384| } Error: GCC_ANALYZER_WARNING (CWE-476): [#def13] pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2387:31: warning[-Wanalyzer-null-dereference]: dereference of NULL ‘0’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2328:1: enter_function: entry to ‘pango_attr_list_splice’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2337:3: branch_true: following ‘true’ branch (when ‘list’ is non-NULL)... pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2338:3: branch_true: ...to here pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2338:3: branch_true: following ‘true’ branch (when ‘other’ is non-NULL)... pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2339:3: branch_true: ...to here pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2339:3: branch_true: following ‘true’ branch (when ‘pos >= 0’)... pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2340:3: branch_true: ...to here pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2340:3: branch_true: following ‘true’ branch (when ‘len >= 0’)... pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2342:3: branch_true: ...to here pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2374:6: branch_false: following ‘false’ branch... pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2377:43: branch_true: following ‘true’ branch... pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2379:52: branch_true: ...to here pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2379:30: call_function: calling ‘pango_attribute_copy’ from ‘pango_attr_list_splice’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2379:30: return_function: returning to ‘pango_attr_list_splice’ from ‘pango_attribute_copy’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2380:10: branch_false: following ‘false’ branch (when ‘ulen == 0’)... pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2387:31: branch_false: ...to here pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2387:31: danger: dereference of NULL ‘pango_attribute_copy(*<unknown>)’ # 2385| else # 2386| { # 2387|-> attr->start_index = CLAMP_ADD (attr->start_index, upos); # 2388| attr->end_index = CLAMP_ADD (attr->end_index, upos); # 2389| } Error: GCC_ANALYZER_WARNING (CWE-465): [#def14] pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2664:11: warning[-Wanalyzer-deref-before-check]: check of ‘attr’ for NULL after already dereferencing it pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2630:1: enter_function: entry to ‘attr_print’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2664:22: call_function: calling ‘pango_attribute_as_string’ from ‘attr_print’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2664:22: return_function: returning to ‘attr_print’ from ‘pango_attribute_as_string’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2664:11: danger: pointer ‘attr’ is checked for NULL here but it was already dereferenced at [(2)](sarif:/runs/0/results/3/codeFlows/0/threadFlows/0/locations/1) # 2662| attr->klass->type == PANGO_ATTR_FALLBACK) # 2663| g_string_append (str, ((PangoAttrInt *)attr)->value ? " true" : " false"); # 2664|-> else if ((string = pango_attribute_as_string (attr)) != NULL) # 2665| { # 2666| char *s = g_strescape (string->value, NULL); Error: GCC_ANALYZER_WARNING (CWE-465): [#def15] pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2670:11: warning[-Wanalyzer-deref-before-check]: check of ‘attr’ for NULL after already dereferencing it pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2630:1: enter_function: entry to ‘attr_print’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2664:22: call_function: calling ‘pango_attribute_as_string’ from ‘attr_print’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2664:22: return_function: returning to ‘attr_print’ from ‘pango_attribute_as_string’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2664:11: branch_false: following ‘false’ branch... pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2670:20: branch_false: ...to here pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2670:20: call_function: calling ‘pango_attribute_as_language’ from ‘attr_print’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2670:20: return_function: returning to ‘attr_print’ from ‘pango_attribute_as_language’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2670:11: danger: pointer ‘attr’ is checked for NULL here but it was already dereferenced at [(2)](sarif:/runs/0/results/5/codeFlows/0/threadFlows/0/locations/1) # 2668| g_free (s); # 2669| } # 2670|-> else if ((lang = pango_attribute_as_language (attr)) != NULL) # 2671| g_string_append_printf (str, " %s", pango_language_to_string (lang->value)); # 2672| else if ((integer = pango_attribute_as_int (attr)) != NULL) Error: GCC_ANALYZER_WARNING (CWE-465): [#def16] pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2672:11: warning[-Wanalyzer-deref-before-check]: check of ‘attr’ for NULL after already dereferencing it pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2630:1: enter_function: entry to ‘attr_print’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2664:22: call_function: calling ‘pango_attribute_as_string’ from ‘attr_print’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2664:22: return_function: returning to ‘attr_print’ from ‘pango_attribute_as_string’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2664:11: branch_false: following ‘false’ branch... pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2670:20: branch_false: ...to here pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2670:20: call_function: calling ‘pango_attribute_as_language’ from ‘attr_print’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2670:20: return_function: returning to ‘attr_print’ from ‘pango_attribute_as_language’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2670:11: branch_false: following ‘false’ branch... pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2672:23: branch_false: ...to here pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2672:23: call_function: calling ‘pango_attribute_as_int’ from ‘attr_print’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2672:23: return_function: returning to ‘attr_print’ from ‘pango_attribute_as_int’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2672:11: danger: pointer ‘attr’ is checked for NULL here but it was already dereferenced at [(2)](sarif:/runs/0/results/7/codeFlows/0/threadFlows/0/locations/1) # 2670| else if ((lang = pango_attribute_as_language (attr)) != NULL) # 2671| g_string_append_printf (str, " %s", pango_language_to_string (lang->value)); # 2672|-> else if ((integer = pango_attribute_as_int (attr)) != NULL) # 2673| g_string_append_printf (str, " %d", integer->value); # 2674| else if ((flt = pango_attribute_as_float (attr)) != NULL) Error: GCC_ANALYZER_WARNING (CWE-465): [#def17] pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2674:11: warning[-Wanalyzer-deref-before-check]: check of ‘attr’ for NULL after already dereferencing it pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2630:1: enter_function: entry to ‘attr_print’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2664:22: call_function: calling ‘pango_attribute_as_string’ from ‘attr_print’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2664:22: return_function: returning to ‘attr_print’ from ‘pango_attribute_as_string’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2664:11: branch_false: following ‘false’ branch... pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2670:20: branch_false: ...to here pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2670:20: call_function: calling ‘pango_attribute_as_language’ from ‘attr_print’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2670:20: return_function: returning to ‘attr_print’ from ‘pango_attribute_as_language’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2670:11: branch_false: following ‘false’ branch... pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2672:23: branch_false: ...to here pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2672:23: call_function: calling ‘pango_attribute_as_int’ from ‘attr_print’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2672:23: return_function: returning to ‘attr_print’ from ‘pango_attribute_as_int’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2672:11: branch_false: following ‘false’ branch... pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2674:19: branch_false: ...to here pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2674:19: call_function: calling ‘pango_attribute_as_float’ from ‘attr_print’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2674:19: return_function: returning to ‘attr_print’ from ‘pango_attribute_as_float’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2674:11: danger: pointer ‘attr’ is checked for NULL here but it was already dereferenced at [(2)](sarif:/runs/0/results/9/codeFlows/0/threadFlows/0/locations/1) # 2672| else if ((integer = pango_attribute_as_int (attr)) != NULL) # 2673| g_string_append_printf (str, " %d", integer->value); # 2674|-> else if ((flt = pango_attribute_as_float (attr)) != NULL) # 2675| { # 2676| char buf[20]; Error: GCC_ANALYZER_WARNING (CWE-465): [#def18] pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2680:11: warning[-Wanalyzer-deref-before-check]: check of ‘attr’ for NULL after already dereferencing it pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2630:1: enter_function: entry to ‘attr_print’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2664:22: call_function: calling ‘pango_attribute_as_string’ from ‘attr_print’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2664:22: return_function: returning to ‘attr_print’ from ‘pango_attribute_as_string’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2664:11: branch_false: following ‘false’ branch... pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2670:20: branch_false: ...to here pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2670:20: call_function: calling ‘pango_attribute_as_language’ from ‘attr_print’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2670:20: return_function: returning to ‘attr_print’ from ‘pango_attribute_as_language’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2670:11: branch_false: following ‘false’ branch... pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2672:23: branch_false: ...to here pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2672:23: call_function: calling ‘pango_attribute_as_int’ from ‘attr_print’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2672:23: return_function: returning to ‘attr_print’ from ‘pango_attribute_as_int’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2672:11: branch_false: following ‘false’ branch... pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2674:19: branch_false: ...to here pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2674:19: call_function: calling ‘pango_attribute_as_float’ from ‘attr_print’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2674:19: return_function: returning to ‘attr_print’ from ‘pango_attribute_as_float’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2674:11: branch_false: following ‘false’ branch... pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2680:20: branch_false: ...to here pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2680:20: call_function: calling ‘pango_attribute_as_font_desc’ from ‘attr_print’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2680:20: return_function: returning to ‘attr_print’ from ‘pango_attribute_as_font_desc’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2680:11: danger: pointer ‘attr’ is checked for NULL here but it was already dereferenced at [(2)](sarif:/runs/0/results/11/codeFlows/0/threadFlows/0/locations/1) # 2678| g_string_append_printf (str, " %s", buf); # 2679| } # 2680|-> else if ((font = pango_attribute_as_font_desc (attr)) != NULL) # 2681| { # 2682| char *s = pango_font_description_to_string (font->desc); Error: GCC_ANALYZER_WARNING (CWE-465): [#def19] pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2688:11: warning[-Wanalyzer-deref-before-check]: check of ‘attr’ for NULL after already dereferencing it pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2630:1: enter_function: entry to ‘attr_print’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2664:22: call_function: calling ‘pango_attribute_as_string’ from ‘attr_print’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2664:22: return_function: returning to ‘attr_print’ from ‘pango_attribute_as_string’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2664:11: branch_false: following ‘false’ branch... pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2670:20: branch_false: ...to here pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2670:20: call_function: calling ‘pango_attribute_as_language’ from ‘attr_print’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2670:20: return_function: returning to ‘attr_print’ from ‘pango_attribute_as_language’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2670:11: branch_false: following ‘false’ branch... pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2672:23: branch_false: ...to here pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2672:23: call_function: calling ‘pango_attribute_as_int’ from ‘attr_print’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2672:23: return_function: returning to ‘attr_print’ from ‘pango_attribute_as_int’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2672:11: branch_false: following ‘false’ branch... pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2674:19: branch_false: ...to here pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2674:19: call_function: calling ‘pango_attribute_as_float’ from ‘attr_print’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2674:19: return_function: returning to ‘attr_print’ from ‘pango_attribute_as_float’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2674:11: branch_false: following ‘false’ branch... pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2680:20: branch_false: ...to here pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2680:20: call_function: calling ‘pango_attribute_as_font_desc’ from ‘attr_print’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2680:20: return_function: returning to ‘attr_print’ from ‘pango_attribute_as_font_desc’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2680:11: branch_false: following ‘false’ branch... pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2688:21: branch_false: ...to here pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2688:21: call_function: calling ‘pango_attribute_as_color’ from ‘attr_print’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2688:21: return_function: returning to ‘attr_print’ from ‘pango_attribute_as_color’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2688:11: danger: pointer ‘attr’ is checked for NULL here but it was already dereferenced at [(2)](sarif:/runs/0/results/13/codeFlows/0/threadFlows/0/locations/1) # 2686| g_free (s); # 2687| } # 2688|-> else if ((color = pango_attribute_as_color (attr)) != NULL) # 2689| { # 2690| char *s = pango_color_to_string (&color->color); Error: GCC_ANALYZER_WARNING (CWE-465): [#def20] pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2694:11: warning[-Wanalyzer-deref-before-check]: check of ‘attr’ for NULL after already dereferencing it pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2630:1: enter_function: entry to ‘attr_print’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2664:22: call_function: calling ‘pango_attribute_as_string’ from ‘attr_print’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2664:22: return_function: returning to ‘attr_print’ from ‘pango_attribute_as_string’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2664:11: branch_false: following ‘false’ branch... pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2670:20: branch_false: ...to here pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2670:20: call_function: calling ‘pango_attribute_as_language’ from ‘attr_print’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2670:20: return_function: returning to ‘attr_print’ from ‘pango_attribute_as_language’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2670:11: branch_false: following ‘false’ branch... pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2672:23: branch_false: ...to here pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2672:23: call_function: calling ‘pango_attribute_as_int’ from ‘attr_print’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2672:23: return_function: returning to ‘attr_print’ from ‘pango_attribute_as_int’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2672:11: branch_false: following ‘false’ branch... pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2674:19: branch_false: ...to here pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2674:19: call_function: calling ‘pango_attribute_as_float’ from ‘attr_print’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2674:19: return_function: returning to ‘attr_print’ from ‘pango_attribute_as_float’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2674:11: branch_false: following ‘false’ branch... pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2680:20: branch_false: ...to here pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2680:20: call_function: calling ‘pango_attribute_as_font_desc’ from ‘attr_print’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2680:20: return_function: returning to ‘attr_print’ from ‘pango_attribute_as_font_desc’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2680:11: branch_false: following ‘false’ branch... pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2688:21: branch_false: ...to here pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2688:21: call_function: calling ‘pango_attribute_as_color’ from ‘attr_print’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2688:21: return_function: returning to ‘attr_print’ from ‘pango_attribute_as_color’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2688:11: branch_false: following ‘false’ branch... pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2694:21: branch_false: ...to here pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2694:21: call_function: calling ‘pango_attribute_as_shape’ from ‘attr_print’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2694:21: return_function: returning to ‘attr_print’ from ‘pango_attribute_as_shape’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2694:11: danger: pointer ‘attr’ is checked for NULL here but it was already dereferenced at [(2)](sarif:/runs/0/results/15/codeFlows/0/threadFlows/0/locations/1) # 2692| g_free (s); # 2693| } # 2694|-> else if ((shape = pango_attribute_as_shape (attr)) != NULL) # 2695| g_string_append (str, "shape"); /* FIXME */ # 2696| else if ((size = pango_attribute_as_size (attr)) != NULL) Error: GCC_ANALYZER_WARNING (CWE-465): [#def21] pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2696:11: warning[-Wanalyzer-deref-before-check]: check of ‘attr’ for NULL after already dereferencing it pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2630:1: enter_function: entry to ‘attr_print’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2664:22: call_function: calling ‘pango_attribute_as_string’ from ‘attr_print’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2664:22: return_function: returning to ‘attr_print’ from ‘pango_attribute_as_string’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2664:11: branch_false: following ‘false’ branch... pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2670:20: branch_false: ...to here pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2670:20: call_function: calling ‘pango_attribute_as_language’ from ‘attr_print’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2670:20: return_function: returning to ‘attr_print’ from ‘pango_attribute_as_language’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2670:11: branch_false: following ‘false’ branch... pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2672:23: branch_false: ...to here pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2672:23: call_function: calling ‘pango_attribute_as_int’ from ‘attr_print’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2672:23: return_function: returning to ‘attr_print’ from ‘pango_attribute_as_int’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2672:11: branch_false: following ‘false’ branch... pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2674:19: branch_false: ...to here pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2674:19: call_function: calling ‘pango_attribute_as_float’ from ‘attr_print’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2674:19: return_function: returning to ‘attr_print’ from ‘pango_attribute_as_float’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2674:11: branch_false: following ‘false’ branch... pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2680:20: branch_false: ...to here pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2680:20: call_function: calling ‘pango_attribute_as_font_desc’ from ‘attr_print’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2680:20: return_function: returning to ‘attr_print’ from ‘pango_attribute_as_font_desc’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2680:11: branch_false: following ‘false’ branch... pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2688:21: branch_false: ...to here pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2688:21: call_function: calling ‘pango_attribute_as_color’ from ‘attr_print’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2688:21: return_function: returning to ‘attr_print’ from ‘pango_attribute_as_color’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2688:11: branch_false: following ‘false’ branch... pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2694:21: branch_false: ...to here pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2694:21: call_function: calling ‘pango_attribute_as_shape’ from ‘attr_print’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2694:21: return_function: returning to ‘attr_print’ from ‘pango_attribute_as_shape’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2694:11: branch_false: following ‘false’ branch... pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2696:20: branch_false: ...to here pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2696:20: call_function: calling ‘pango_attribute_as_size’ from ‘attr_print’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2696:20: return_function: returning to ‘attr_print’ from ‘pango_attribute_as_size’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2696:11: danger: pointer ‘attr’ is checked for NULL here but it was already dereferenced at [(2)](sarif:/runs/0/results/17/codeFlows/0/threadFlows/0/locations/1) # 2694| else if ((shape = pango_attribute_as_shape (attr)) != NULL) # 2695| g_string_append (str, "shape"); /* FIXME */ # 2696|-> else if ((size = pango_attribute_as_size (attr)) != NULL) # 2697| g_string_append_printf (str, " %d", size->size); # 2698| else if ((features = pango_attribute_as_font_features (attr)) != NULL) Error: GCC_ANALYZER_WARNING (CWE-465): [#def22] pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2698:11: warning[-Wanalyzer-deref-before-check]: check of ‘attr’ for NULL after already dereferencing it pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2630:1: enter_function: entry to ‘attr_print’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2664:22: call_function: calling ‘pango_attribute_as_string’ from ‘attr_print’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2664:22: return_function: returning to ‘attr_print’ from ‘pango_attribute_as_string’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2664:11: branch_false: following ‘false’ branch... pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2670:20: branch_false: ...to here pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2670:20: call_function: calling ‘pango_attribute_as_language’ from ‘attr_print’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2670:20: return_function: returning to ‘attr_print’ from ‘pango_attribute_as_language’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2670:11: branch_false: following ‘false’ branch... pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2672:23: branch_false: ...to here pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2672:23: call_function: calling ‘pango_attribute_as_int’ from ‘attr_print’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2672:23: return_function: returning to ‘attr_print’ from ‘pango_attribute_as_int’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2672:11: branch_false: following ‘false’ branch... pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2674:19: branch_false: ...to here pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2674:19: call_function: calling ‘pango_attribute_as_float’ from ‘attr_print’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2674:19: return_function: returning to ‘attr_print’ from ‘pango_attribute_as_float’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2674:11: branch_false: following ‘false’ branch... pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2680:20: branch_false: ...to here pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2680:20: call_function: calling ‘pango_attribute_as_font_desc’ from ‘attr_print’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2680:20: return_function: returning to ‘attr_print’ from ‘pango_attribute_as_font_desc’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2680:11: branch_false: following ‘false’ branch... pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2688:21: branch_false: ...to here pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2688:21: call_function: calling ‘pango_attribute_as_color’ from ‘attr_print’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2688:21: return_function: returning to ‘attr_print’ from ‘pango_attribute_as_color’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2688:11: branch_false: following ‘false’ branch... pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2694:21: branch_false: ...to here pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2694:21: call_function: calling ‘pango_attribute_as_shape’ from ‘attr_print’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2694:21: return_function: returning to ‘attr_print’ from ‘pango_attribute_as_shape’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2694:11: branch_false: following ‘false’ branch... pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2696:20: branch_false: ...to here pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2696:20: call_function: calling ‘pango_attribute_as_size’ from ‘attr_print’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2696:20: return_function: returning to ‘attr_print’ from ‘pango_attribute_as_size’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2696:11: branch_false: following ‘false’ branch... pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2698:24: branch_false: ...to here pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2698:24: call_function: calling ‘pango_attribute_as_font_features’ from ‘attr_print’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2698:24: return_function: returning to ‘attr_print’ from ‘pango_attribute_as_font_features’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2698:11: danger: pointer ‘attr’ is checked for NULL here but it was already dereferenced at [(2)](sarif:/runs/0/results/19/codeFlows/0/threadFlows/0/locations/1) # 2696| else if ((size = pango_attribute_as_size (attr)) != NULL) # 2697| g_string_append_printf (str, " %d", size->size); # 2698|-> else if ((features = pango_attribute_as_font_features (attr)) != NULL) # 2699| g_string_append_printf (str, " \"%s\"", features->features); # 2700| else Error: GCC_ANALYZER_WARNING (CWE-476): [#def23] pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:3146:7: warning[-Wanalyzer-null-dereference]: dereference of NULL ‘attr’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2832:1: enter_function: entry to ‘pango_attr_list_from_string’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2837:3: branch_true: following ‘true’ branch (when ‘text’ is non-NULL)... pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2839:10: branch_true: ...to here pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2841:6: branch_false: following ‘false’ branch... pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2844:22: branch_false: ...to here pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2847:10: branch_true: following ‘true’ branch... pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2861:10: branch_true: ...to here pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2888:10: branch_false: following ‘false’ branch... pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2964:7: branch_false: ...to here pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2998:18: call_function: calling ‘pango_attr_family_new’ from ‘pango_attr_list_from_string’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:2998:18: return_function: returning to ‘pango_attr_list_from_string’ from ‘pango_attr_family_new’ pango-1.56.3/redhat-linux-build/../pango/pango-attributes.c:3146:7: danger: dereference of NULL ‘attr’ # 3144| } # 3145| # 3146|-> attr->start_index = (guint)start_index; # 3147| attr->end_index = (guint)end_index; # 3148| g_ptr_array_add (list->attributes, attr); Error: GCC_ANALYZER_WARNING (CWE-835): [#def24] pango-1.56.3/redhat-linux-build/../pango/pango-color.c:164:14: warning[-Wanalyzer-infinite-loop]: infinite loop pango-1.56.3/redhat-linux-build/../pango/pango-color.c:164:14: danger: infinite loop here pango-1.56.3/redhat-linux-build/../pango/pango-color.c:164:14: branch_true: if it ever follows ‘true’ branch, it will always do so... pango-1.56.3/redhat-linux-build/../pango/pango-color.c:164:26: branch_true: ...to here # 162| int c1, c2; # 163| while (*s1 == ' ') s1++; # 164|-> while (*s2 == ' ') s1++; # 165| c1 = (gint)(guchar) TOLOWER (*s1); # 166| c2 = (gint)(guchar) TOLOWER (*s2); Error: GCC_ANALYZER_WARNING (CWE-476): [#def25] pango-1.56.3/redhat-linux-build/../pango/pango-tabs.c:191:7: warning[-Wanalyzer-null-dereference]: dereference of NULL ‘0’ pango-1.56.3/redhat-linux-build/../pango/pango-tabs.c:183:1: enter_function: entry to ‘pango_tab_array_copy’ pango-1.56.3/redhat-linux-build/../pango/pango-tabs.c:187:3: branch_true: following ‘true’ branch (when ‘src’ is non-NULL)... pango-1.56.3/redhat-linux-build/../pango/pango-tabs.c:189:10: branch_true: ...to here pango-1.56.3/redhat-linux-build/../pango/pango-tabs.c:189:10: call_function: calling ‘pango_tab_array_new’ from ‘pango_tab_array_copy’ pango-1.56.3/redhat-linux-build/../pango/pango-tabs.c:189:10: return_function: returning to ‘pango_tab_array_copy’ from ‘pango_tab_array_new’ pango-1.56.3/redhat-linux-build/../pango/pango-tabs.c:191:7: danger: dereference of NULL ‘pango_tab_array_new(*src.size, *src.positions_in_pixels)’ # 189| copy = pango_tab_array_new (src->size, src->positions_in_pixels); # 190| # 191|-> if (copy->tabs) # 192| memcpy (copy->tabs, src->tabs, sizeof(PangoTab) * src->size); # 193| Error: GCC_ANALYZER_WARNING (CWE-476): [#def26] pango-1.56.3/redhat-linux-build/../pango/pangocairo-font.c:245:3: warning[-Wanalyzer-null-dereference]: dereference of NULL ‘cf_priv’ pango-1.56.3/redhat-linux-build/../pango/pangocairo-font.c:238:36: branch_false: following ‘false’ branch (when ‘font’ is NULL)... pango-1.56.3/redhat-linux-build/../pango/pangocairo-font.c:243:28: branch_false: ...to here pango-1.56.3/redhat-linux-build/../pango/pangocairo-font.c:245:3: danger: dereference of NULL ‘cf_priv’ # 243| const char *sample_str = pango_language_get_sample_string (language); # 244| # 245|-> tmp_list = cf_priv->metrics_by_lang; # 246| while (tmp_list) # 247| { Error: GCC_ANALYZER_WARNING (CWE-476): [#def27] pango-1.56.3/redhat-linux-build/../pango/pangofc-fontmap.c:834:17: warning[-Wanalyzer-possible-null-dereference]: dereference of possibly-NULL ‘copy’ pango-1.56.3/redhat-linux-build/../pango/pangofc-fontmap.c:2515:1: enter_function: entry to ‘pango_fc_font_map_load_fontset’ pango-1.56.3/redhat-linux-build/../pango/pangofc-fontmap.c:2525:3: call_function: calling ‘pango_fc_fontset_key_init’ from ‘pango_fc_font_map_load_fontset’ pango-1.56.3/redhat-linux-build/../pango/pangofc-fontmap.c:2525:3: return_function: returning to ‘pango_fc_font_map_load_fontset’ from ‘pango_fc_fontset_key_init’ pango-1.56.3/redhat-linux-build/../pango/pangofc-fontmap.c:2529:7: branch_true: following ‘true’ branch... pango-1.56.3/redhat-linux-build/../pango/pangofc-fontmap.c:2531:35: branch_true: ...to here pango-1.56.3/redhat-linux-build/../pango/pangofc-fontmap.c:2531:35: call_function: calling ‘pango_fc_font_map_get_patterns’ from ‘pango_fc_font_map_load_fontset’ # 832| # 833| copy = malloc (sizeof (FcFontSet)); # 834|-> copy->sfont = copy->nfont = fontset->nfont; # 835| copy->fonts = malloc (sizeof (FcPattern *) * copy->nfont); # 836| memcpy (copy->fonts, fontset->fonts, sizeof (FcPattern *) * copy->nfont); Error: GCC_ANALYZER_WARNING (CWE-476): [#def28] pango-1.56.3/redhat-linux-build/../pango/pangofc-fontmap.c:838:5: warning[-Wanalyzer-possible-null-dereference]: dereference of possibly-NULL ‘malloc((long unsigned int)*fontset.nfont * 8)’ pango-1.56.3/redhat-linux-build/../pango/pangofc-fontmap.c:2515:1: enter_function: entry to ‘pango_fc_font_map_load_fontset’ pango-1.56.3/redhat-linux-build/../pango/pangofc-fontmap.c:2525:3: call_function: calling ‘pango_fc_fontset_key_init’ from ‘pango_fc_font_map_load_fontset’ pango-1.56.3/redhat-linux-build/../pango/pangofc-fontmap.c:2525:3: return_function: returning to ‘pango_fc_font_map_load_fontset’ from ‘pango_fc_fontset_key_init’ pango-1.56.3/redhat-linux-build/../pango/pangofc-fontmap.c:2529:7: branch_true: following ‘true’ branch... pango-1.56.3/redhat-linux-build/../pango/pangofc-fontmap.c:2531:35: branch_true: ...to here pango-1.56.3/redhat-linux-build/../pango/pangofc-fontmap.c:2531:35: call_function: calling ‘pango_fc_font_map_get_patterns’ from ‘pango_fc_font_map_load_fontset’ # 836| memcpy (copy->fonts, fontset->fonts, sizeof (FcPattern *) * copy->nfont); # 837| for (i = 0; i < copy->nfont; i++) # 838|-> FcPatternReference (copy->fonts[i]); # 839| # 840| return copy; Error: GCC_ANALYZER_WARNING (CWE-476): [#def29] pango-1.56.3/redhat-linux-build/../pango/pangofc-fontmap.c:3821:8: warning[-Wanalyzer-null-dereference]: dereference of NULL ‘0’ # 3819| data = pango_fc_font_map_get_font_face_data (fcfontmap, fcfont->font_pattern); # 3820| # 3821|-> if (!data->hb_face) # 3822| { # 3823| hb_blob_t *blob; Error: GCC_ANALYZER_WARNING (CWE-476): [#def30] pango-1.56.3/redhat-linux-build/../pango/pangoxft-render.c:417:112: warning[-Wanalyzer-null-dereference]: dereference of NULL ‘xfont’ pango-1.56.3/redhat-linux-build/../pango/pangoxft-render.c:454:1: enter_function: entry to ‘pango_xft_renderer_draw_glyphs’ pango-1.56.3/redhat-linux-build/../pango/pangoxft-render.c:466:6: branch_true: following ‘true’ branch (when ‘font’ is NULL)... branch_true: ...to here pango-1.56.3/redhat-linux-build/../pango/pangoxft-render.c:468:17: branch_true: following ‘true’ branch... pango-1.56.3/redhat-linux-build/../pango/pangoxft-render.c:470:33: branch_true: ...to here pango-1.56.3/redhat-linux-build/../pango/pangoxft-render.c:472:14: branch_true: following ‘true’ branch... pango-1.56.3/redhat-linux-build/../pango/pangoxft-render.c:474:29: branch_true: ...to here pango-1.56.3/redhat-linux-build/../pango/pangoxft-render.c:477:15: call_function: calling ‘_pango_xft_renderer_draw_unknown_glyph’ from ‘pango_xft_renderer_draw_glyphs’ # 415| # 416| # 417|-> ys[0] = glyph_y - PANGO_SCALE * xft_font->ascent + PANGO_SCALE * (((xft_font->ascent + xft_font->descent) - (xfont->mini_height * 2 + xfont->mini_pad * 5 + PANGO_SCALE / 2) / PANGO_SCALE) / 2); # 418| ys[1] = ys[0] + 2 * xfont->mini_pad + xfont->mini_height; # 419| ys[2] = ys[1] + xfont->mini_height + xfont->mini_pad; Error: GCC_ANALYZER_WARNING (CWE-457): [#def31] pango-1.56.3/redhat-linux-build/../pango/shape.c:505:9: warning[-Wanalyzer-use-of-uninitialized-value]: use of uninitialized value ‘hyphen_index’ pango-1.56.3/redhat-linux-build/../pango/shape.c:912:1: enter_function: entry to ‘pango_shape_with_flags’ pango-1.56.3/redhat-linux-build/../pango/shape.c:920:3: call_function: calling ‘pango_shape_internal’ from ‘pango_shape_with_flags’ # 503| /* Note: We rely on hb_buffer_add clearing existing post-context */ # 504| if (hb_font_get_nominal_glyph (hb_font, 0x2010, &glyph)) # 505|-> hb_buffer_add (hb_buffer, 0x2010, hyphen_index); # 506| else if (hb_font_get_nominal_glyph (hb_font, '-', &glyph)) # 507| hb_buffer_add (hb_buffer, '-', hyphen_index); Error: GCC_ANALYZER_WARNING (CWE-457): [#def32] pango-1.56.3/redhat-linux-build/../pango/shape.c:507:9: warning[-Wanalyzer-use-of-uninitialized-value]: use of uninitialized value ‘hyphen_index’ pango-1.56.3/redhat-linux-build/../pango/shape.c:953:1: enter_function: entry to ‘pango_shape_item’ pango-1.56.3/redhat-linux-build/../pango/shape.c:960:3: call_function: calling ‘pango_shape_internal’ from ‘pango_shape_item’ # 505| hb_buffer_add (hb_buffer, 0x2010, hyphen_index); # 506| else if (hb_font_get_nominal_glyph (hb_font, '-', &glyph)) # 507|-> hb_buffer_add (hb_buffer, '-', hyphen_index); # 508| } # 509| Error: GCC_ANALYZER_WARNING (CWE-688): [#def33] pango-1.56.3/redhat-linux-build/../tests/markup-parse.c:103:7: warning[-Wanalyzer-null-argument]: use of NULL where non-null expected pango-1.56.3/redhat-linux-build/../tests/markup-parse.c:98:1: enter_function: entry to ‘get_expected_filename’ pango-1.56.3/redhat-linux-build/../tests/markup-parse.c:103:7: danger: argument 1 (‘<unknown>’) NULL where non-null expected #argument 1 of ‘__builtin_strstr’ must be non-null # 101| # 102| f = g_strdup (filename); # 103|-> p = strstr (f, ".markup"); # 104| if (p) # 105| *p = 0; Error: GCC_ANALYZER_WARNING (CWE-688): [#def34] pango-1.56.3/redhat-linux-build/../tests/test-common.c:161:3: warning[-Wanalyzer-null-argument]: use of NULL ‘diff’ where non-null expected pango-1.56.3/redhat-linux-build/../tests/test-common.c:109:9: release_memory: ‘diff’ is NULL pango-1.56.3/redhat-linux-build/../tests/test-common.c:109:23: release_memory: ‘diff’ is NULL pango-1.56.3/redhat-linux-build/../tests/test-common.c:109:40: release_memory: ‘diff’ is NULL pango-1.56.3/redhat-linux-build/../tests/test-common.c:116:6: branch_false: following ‘false’ branch... pango-1.56.3/redhat-linux-build/../tests/test-common.c:119:25: branch_false: ...to here pango-1.56.3/redhat-linux-build/../tests/test-common.c:120:6: branch_true: following ‘true’ branch... pango-1.56.3/redhat-linux-build/../tests/test-common.c:122:7: branch_true: ...to here pango-1.56.3/redhat-linux-build/../tests/test-common.c:161:3: release_memory: ‘diff’ is NULL pango-1.56.3/redhat-linux-build/../tests/test-common.c:162:3: release_memory: ‘diff’ is NULL pango-1.56.3/redhat-linux-build/../tests/test-common.c:164:10: release_memory: ‘diff’ is NULL pango-1.56.3/redhat-linux-build/../tests/test-common.c:161:3: danger: argument 1 (‘tmpfile2’) NULL where non-null expected # 159| unlink (tmpfile); # 160| g_free (tmpfile); # 161|-> unlink (tmpfile2); # 162| g_free (tmpfile2); # 163| Error: GCC_ANALYZER_WARNING (CWE-688): [#def35] pango-1.56.3/redhat-linux-build/../tests/test-itemize.c:246:7: warning[-Wanalyzer-null-argument]: use of NULL where non-null expected pango-1.56.3/redhat-linux-build/../tests/test-itemize.c:257:1: enter_function: entry to ‘test_itemize’ pango-1.56.3/redhat-linux-build/../tests/test-itemize.c:272:6: branch_false: following ‘false’ branch... pango-1.56.3/redhat-linux-build/../tests/test-itemize.c:281:13: branch_false: ...to here pango-1.56.3/redhat-linux-build/../tests/test-itemize.c:299:6: branch_false: following ‘false’ branch (when ‘found_cantarell != 0’)... pango-1.56.3/redhat-linux-build/../tests/test-itemize.c:308:19: branch_false: ...to here pango-1.56.3/redhat-linux-build/../tests/test-itemize.c:308:19: call_function: calling ‘get_expected_filename’ from ‘test_itemize’ #argument 1 of ‘__builtin_strstr’ must be non-null # 244| # 245| f = g_strdup (filename); # 246|-> p = strstr (f, ".items"); # 247| if (p) # 248| *p = 0; Error: GCC_ANALYZER_WARNING (CWE-688): [#def36] pango-1.56.3/redhat-linux-build/../tests/test-shape.c:351:7: warning[-Wanalyzer-null-argument]: use of NULL where non-null expected pango-1.56.3/redhat-linux-build/../tests/test-shape.c:362:1: enter_function: entry to ‘test_shape’ pango-1.56.3/redhat-linux-build/../tests/test-shape.c:370:19: call_function: calling ‘get_expected_filename’ from ‘test_shape’ #argument 1 of ‘__builtin_strstr’ must be non-null # 349| # 350| f = g_strdup (filename); # 351|-> p = strstr (f, ".shape"); # 352| if (p) # 353| *p = 0; Error: CPPCHECK_WARNING (CWE-664): [#def37] pango-1.56.3/utils/viewer-render.c:98: error[va_end_missing]: va_list 'vap' was opened but not closed by va_end(). # 96| # 97| exit (1); # 98|-> } # 99| # 100| static PangoLayout *
analyzer-version-clippy | 1.86.0 |
analyzer-version-cppcheck | 2.17.1 |
analyzer-version-gcc | 15.0.1 |
analyzer-version-gcc-analyzer | 15.0.1 |
analyzer-version-shellcheck | 0.10.0 |
analyzer-version-unicontrol | 0.0.2 |
enabled-plugins | clippy, cppcheck, gcc, shellcheck, unicontrol |
exit-code | 0 |
host | ip-172-16-1-182.us-west-2.compute.internal |
known-false-positives | /usr/share/csmock/known-false-positives.js |
known-false-positives-rpm | known-false-positives-0.0.0.20250425.124705.g1c7c448.main-1.el9.noarch |
mock-config | fedora-rawhide-x86_64 |
project-name | pango-1.56.3-1.fc43 |
store-results-to | /tmp/tmpyh3rf_3k/pango-1.56.3-1.fc43.tar.xz |
time-created | 2025-04-25 14:43:31 |
time-finished | 2025-04-25 14:45:41 |
tool | csmock |
tool-args | '/usr/bin/csmock' '-r' 'fedora-rawhide-x86_64' '-t' 'unicontrol,cppcheck,gcc,clippy,shellcheck' '-o' '/tmp/tmpyh3rf_3k/pango-1.56.3-1.fc43.tar.xz' '--gcc-analyze' '--unicontrol-notests' '--unicontrol-bidi-only' '--install' 'pam' '--gcc-analyzer-bin=/usr/bin/gcc' '/tmp/tmpyh3rf_3k/pango-1.56.3-1.fc43.src.rpm' |
tool-version | csmock-3.8.1.20250422.172604.g26bc3d6-1.el9 |