Error: GCC_ANALYZER_WARNING (CWE-457): [#def1] Pillow-12.2.0/src/_imaging.c:1123:9: warning[-Wanalyzer-use-of-uninitialized-value]: use of uninitialized value ‘kernelsize’ Pillow-12.2.0/src/_imaging.c:1104:1: enter_function: entry to ‘_filter’ Pillow-12.2.0/src/_imaging.c:1112:8: branch_false: following ‘false’ branch... Pillow-12.2.0/src/_imaging.c:1119:18: branch_false: ...to here Pillow-12.2.0/src/_imaging.c:1119:18: call_function: calling ‘getlist’ from ‘_filter’ Pillow-12.2.0/src/_imaging.c:1119:18: return_function: returning to ‘_filter’ from ‘getlist’ Pillow-12.2.0/src/_imaging.c:1120:8: branch_false: following ‘false’ branch... Pillow-12.2.0/src/_imaging.c:1123:23: branch_false: ...to here Pillow-12.2.0/src/_imaging.c:1123:9: danger: use of uninitialized value ‘kernelsize’ here # 1121| return NULL; # 1122| } # 1123|-> if (kernelsize != (Py_ssize_t)xsize * (Py_ssize_t)ysize) { # 1124| free(kerneldata); # 1125| return ImagingError_ValueError("bad kernel size"); Error: GCC_ANALYZER_WARNING (CWE-457): [#def2] Pillow-12.2.0/src/_imaging.c:2807:9: warning[-Wanalyzer-use-of-uninitialized-value]: use of uninitialized value ‘buffer’ Pillow-12.2.0/src/_imaging.c:2786:1: enter_function: entry to ‘_font_text_asBytes’ Pillow-12.2.0/src/_imaging.c:2795:8: branch_false: following ‘false’ branch... Pillow-12.2.0/src/_imaging.c:2801:16: call_function: inlined call to ‘PyType_HasFeature’ from ‘_font_text_asBytes’ Pillow-12.2.0/src/_imaging.c:2801:15: branch_false: following ‘false’ branch... Pillow-12.2.0/src/_imaging.c:2805:20: branch_false: ...to here Pillow-12.2.0/src/_imaging.c:2806:8: branch_true: following ‘true’ branch... Pillow-12.2.0/src/_imaging.c:2807:9: branch_true: ...to here Pillow-12.2.0/src/_imaging.c:2807:9: danger: use of uninitialized value ‘buffer’ here # 2805| *text = calloc(len + 1, 1); # 2806| if (*text) { # 2807|-> memcpy(*text, buffer, len); # 2808| } else { # 2809| ImagingError_MemoryError(); Error: GCC_ANALYZER_WARNING (CWE-401): [#def3] Pillow-12.2.0/src/encode.c:1101:9: warning[-Wanalyzer-malloc-leak]: leak of ‘get_qtables_arrays(qtables, & qtablesLen)’ Pillow-12.2.0/src/encode.c:1147:1: enter_function: entry to ‘PyImaging_JpegEncoderNew’ Pillow-12.2.0/src/encode.c:1172:8: branch_false: following ‘false’ branch... Pillow-12.2.0/src/encode.c:1199:15: branch_false: ...to here Pillow-12.2.0/src/encode.c:1199:15: call_function: calling ‘PyImaging_EncoderNew’ from ‘PyImaging_JpegEncoderNew’ Pillow-12.2.0/src/encode.c:1199:15: return_function: returning to ‘PyImaging_JpegEncoderNew’ from ‘PyImaging_EncoderNew’ Pillow-12.2.0/src/encode.c:1200:8: branch_false: following ‘false’ branch... Pillow-12.2.0/src/encode.c:1204:25: branch_false: ...to here Pillow-12.2.0/src/encode.c:1214:9: call_function: calling ‘get_packer’ from ‘PyImaging_JpegEncoderNew’ Pillow-12.2.0/src/encode.c:1214:9: return_function: returning to ‘PyImaging_JpegEncoderNew’ from ‘get_packer’ Pillow-12.2.0/src/encode.c:1214:8: branch_false: following ‘false’ branch... Pillow-12.2.0/src/encode.c:1219:15: branch_false: ...to here Pillow-12.2.0/src/encode.c:1219:15: call_function: calling ‘get_qtables_arrays’ from ‘PyImaging_JpegEncoderNew’ Pillow-12.2.0/src/encode.c:1219:15: return_function: returning to ‘PyImaging_JpegEncoderNew’ from ‘get_qtables_arrays’ Pillow-12.2.0/src/encode.c:1221:8: branch_true: following ‘true’ branch... Pillow-12.2.0/src/encode.c:1101:9: danger: ‘get_qtables_arrays(qtables, & qtablesLen)’ leaks here; was allocated at [(32)](sarif:/runs/0/results/0/codeFlows/0/threadFlows/0/locations/31) # 1099| tables = PySequence_Fast(qtables, "expected a sequence"); # 1100| num_tables = PySequence_Size(qtables); # 1101|-> if (num_tables < 1 || num_tables > NUM_QUANT_TBLS) { # 1102| PyErr_SetString( # 1103| PyExc_ValueError, Error: COMPILER_WARNING: [#def4] Pillow-12.2.0/src/libImaging/Arrow.c: scope_hint: In function ‘export_named_type’ Pillow-12.2.0/src/libImaging/Arrow.c:175:5: warning[-Wstringop-truncation]: ‘__strncpy_chk’ specified bound depends on the length of the source argument # 175 | strncpy(formatp, format, format_len); # | ^ Pillow-12.2.0/src/libImaging/Arrow.c:160:25: note: length computed here # 160 | size_t format_len = strlen(format) + 1; # | ^~~~~~~~~~~~~~ # 173| } # 174| # 175|-> strncpy(formatp, format, format_len); # 176| strncpy(namep, name, name_len); # 177| Error: COMPILER_WARNING: [#def5] Pillow-12.2.0/src/libImaging/Arrow.c:176:5: warning[-Wstringop-truncation]: ‘__strncpy_chk’ specified bound depends on the length of the source argument # 176 | strncpy(namep, name, name_len); # | ^ Pillow-12.2.0/src/libImaging/Arrow.c:161:23: note: length computed here # 161 | size_t name_len = strlen(name) + 1; # | ^~~~~~~~~~~~ # 174| # 175| strncpy(formatp, format, format_len); # 176|-> strncpy(namep, name, name_len); # 177| # 178| *schema = (struct ArrowSchema){ Error: GCC_ANALYZER_WARNING (CWE-416): [#def6] Pillow-12.2.0/src/libImaging/Draw.c:1987:9: warning[-Wanalyzer-use-after-free]: use after ‘free’ of ‘eIn’ Pillow-12.2.0/src/libImaging/Draw.c:1963:1: enter_function: entry to ‘ImagingOutlineTransform’ Pillow-12.2.0/src/libImaging/Draw.c:1980:12: call_function: calling ‘allocate’ from ‘ImagingOutlineTransform’ Pillow-12.2.0/src/libImaging/Draw.c:1980:12: return_function: returning to ‘ImagingOutlineTransform’ from ‘allocate’ Pillow-12.2.0/src/libImaging/Draw.c:1981:8: branch_false: following ‘false’ branch... Pillow-12.2.0/src/libImaging/Draw.c:1981:8: branch_false: ...to here Pillow-12.2.0/src/libImaging/Draw.c:1986:17: branch_true: following ‘true’ branch (when ‘i < n’)... Pillow-12.2.0/src/libImaging/Draw.c:1987:9: branch_true: ...to here Pillow-12.2.0/src/libImaging/Draw.c:1987:9: danger: use after ‘free’ of ‘eIn’; freed at [(10)](sarif:/runs/0/results/0/codeFlows/0/threadFlows/0/locations/9) # 1985| # 1986| for (i = 0; i < n; i++) { # 1987|-> x0 = eIn->x0; # 1988| y0 = eIn->y0; # 1989| Error: GCC_ANALYZER_WARNING (CWE-457): [#def7] Pillow-12.2.0/src/libImaging/RankFilter.c:60:1: warning[-Wanalyzer-use-of-uninitialized-value]: use of uninitialized value ‘*<unknown>’ Pillow-12.2.0/src/libImaging/RankFilter.c:62:13: enter_function: entry to ‘ImagingRankFilter’ Pillow-12.2.0/src/libImaging/RankFilter.c:67:8: branch_false: following ‘false’ branch... Pillow-12.2.0/src/libImaging/RankFilter.c:71:8: branch_false: following ‘false’ branch... Pillow-12.2.0/src/libImaging/RankFilter.c:76:16: branch_false: ...to here Pillow-12.2.0/src/libImaging/RankFilter.c:76:8: branch_false: following ‘false’ branch... Pillow-12.2.0/src/libImaging/RankFilter.c:83:8: branch_false: following ‘false’ branch... Pillow-12.2.0/src/libImaging/RankFilter.c:87:58: branch_false: ...to here Pillow-12.2.0/src/libImaging/RankFilter.c:88:8: branch_false: following ‘false’ branch... Pillow-12.2.0/src/libImaging/RankFilter.c:114:9: branch_false: ...to here Pillow-12.2.0/src/libImaging/RankFilter.c:114:8: branch_true: following ‘true’ branch... Pillow-12.2.0/src/libImaging/RankFilter.c:115:9: branch_true: ...to here Pillow-12.2.0/src/libImaging/RankFilter.c:115:9: branch_false: following ‘false’ branch (when ‘buf’ is non-NULL)... Pillow-12.2.0/src/libImaging/RankFilter.c:115:9: branch_false: ...to here Pillow-12.2.0/src/libImaging/RankFilter.c:115:9: branch_true: following ‘true’ branch... Pillow-12.2.0/src/libImaging/RankFilter.c:115:9: branch_true: ...to here Pillow-12.2.0/src/libImaging/RankFilter.c:115:9: branch_false: following ‘false’ branch (when ‘i >= size’)... Pillow-12.2.0/src/libImaging/RankFilter.c:115:9: branch_false: ...to here Pillow-12.2.0/src/libImaging/RankFilter.c:115:9: call_function: calling ‘RankUINT8’ from ‘ImagingRankFilter’ # 58| } # 59| # 60|-> MakeRankFunction(UINT8) MakeRankFunction(INT32) MakeRankFunction(FLOAT32) # 61| # 62| Imaging ImagingRankFilter(Imaging im, int size, int rank) { Error: GCC_ANALYZER_WARNING (CWE-457): [#def8] Pillow-12.2.0/src/libImaging/RankFilter.c:60:25: warning[-Wanalyzer-use-of-uninitialized-value]: use of uninitialized value ‘*<unknown>’ Pillow-12.2.0/src/libImaging/RankFilter.c:62:13: enter_function: entry to ‘ImagingRankFilter’ Pillow-12.2.0/src/libImaging/RankFilter.c:67:8: branch_false: following ‘false’ branch... Pillow-12.2.0/src/libImaging/RankFilter.c:71:8: branch_false: following ‘false’ branch... Pillow-12.2.0/src/libImaging/RankFilter.c:76:16: branch_false: ...to here Pillow-12.2.0/src/libImaging/RankFilter.c:76:8: branch_false: following ‘false’ branch... Pillow-12.2.0/src/libImaging/RankFilter.c:83:8: branch_false: following ‘false’ branch... Pillow-12.2.0/src/libImaging/RankFilter.c:87:58: branch_false: ...to here Pillow-12.2.0/src/libImaging/RankFilter.c:88:8: branch_false: following ‘false’ branch... Pillow-12.2.0/src/libImaging/RankFilter.c:114:9: branch_false: ...to here Pillow-12.2.0/src/libImaging/RankFilter.c:114:8: branch_false: following ‘false’ branch... Pillow-12.2.0/src/libImaging/RankFilter.c:116:16: branch_false: ...to here Pillow-12.2.0/src/libImaging/RankFilter.c:116:15: branch_true: following ‘true’ branch... Pillow-12.2.0/src/libImaging/RankFilter.c:117:9: branch_true: ...to here Pillow-12.2.0/src/libImaging/RankFilter.c:117:9: branch_false: following ‘false’ branch (when ‘buf’ is non-NULL)... Pillow-12.2.0/src/libImaging/RankFilter.c:117:9: branch_false: ...to here Pillow-12.2.0/src/libImaging/RankFilter.c:117:9: branch_true: following ‘true’ branch... Pillow-12.2.0/src/libImaging/RankFilter.c:117:9: branch_true: ...to here Pillow-12.2.0/src/libImaging/RankFilter.c:117:9: branch_false: following ‘false’ branch (when ‘i >= size’)... Pillow-12.2.0/src/libImaging/RankFilter.c:117:9: branch_false: ...to here Pillow-12.2.0/src/libImaging/RankFilter.c:117:9: call_function: calling ‘RankINT32’ from ‘ImagingRankFilter’ # 58| } # 59| # 60|-> MakeRankFunction(UINT8) MakeRankFunction(INT32) MakeRankFunction(FLOAT32) # 61| # 62| Imaging ImagingRankFilter(Imaging im, int size, int rank) { Error: GCC_ANALYZER_WARNING (CWE-457): [#def9] Pillow-12.2.0/src/libImaging/RankFilter.c:60:49: warning[-Wanalyzer-use-of-uninitialized-value]: use of uninitialized value ‘*<unknown>’ Pillow-12.2.0/src/libImaging/RankFilter.c:62:13: enter_function: entry to ‘ImagingRankFilter’ Pillow-12.2.0/src/libImaging/RankFilter.c:67:8: branch_false: following ‘false’ branch... Pillow-12.2.0/src/libImaging/RankFilter.c:71:8: branch_false: following ‘false’ branch... Pillow-12.2.0/src/libImaging/RankFilter.c:76:16: branch_false: ...to here Pillow-12.2.0/src/libImaging/RankFilter.c:76:8: branch_false: following ‘false’ branch... Pillow-12.2.0/src/libImaging/RankFilter.c:83:8: branch_false: following ‘false’ branch... Pillow-12.2.0/src/libImaging/RankFilter.c:87:58: branch_false: ...to here Pillow-12.2.0/src/libImaging/RankFilter.c:88:8: branch_false: following ‘false’ branch... Pillow-12.2.0/src/libImaging/RankFilter.c:114:9: branch_false: ...to here Pillow-12.2.0/src/libImaging/RankFilter.c:114:8: branch_false: following ‘false’ branch... Pillow-12.2.0/src/libImaging/RankFilter.c:116:16: branch_false: ...to here Pillow-12.2.0/src/libImaging/RankFilter.c:116:15: branch_false: following ‘false’ branch... Pillow-12.2.0/src/libImaging/RankFilter.c:118:15: branch_false: ...to here Pillow-12.2.0/src/libImaging/RankFilter.c:118:15: branch_true: following ‘true’ branch... Pillow-12.2.0/src/libImaging/RankFilter.c:119:9: branch_true: ...to here Pillow-12.2.0/src/libImaging/RankFilter.c:119:9: branch_false: following ‘false’ branch (when ‘buf’ is non-NULL)... Pillow-12.2.0/src/libImaging/RankFilter.c:119:9: branch_false: ...to here Pillow-12.2.0/src/libImaging/RankFilter.c:119:9: branch_true: following ‘true’ branch... Pillow-12.2.0/src/libImaging/RankFilter.c:119:9: branch_true: ...to here Pillow-12.2.0/src/libImaging/RankFilter.c:119:9: branch_false: following ‘false’ branch (when ‘i >= size’)... Pillow-12.2.0/src/libImaging/RankFilter.c:119:9: branch_false: ...to here Pillow-12.2.0/src/libImaging/RankFilter.c:119:9: call_function: calling ‘RankFLOAT32’ from ‘ImagingRankFilter’ # 58| } # 59| # 60|-> MakeRankFunction(UINT8) MakeRankFunction(INT32) MakeRankFunction(FLOAT32) # 61| # 62| Imaging ImagingRankFilter(Imaging im, int size, int rank) { Error: GCC_ANALYZER_WARNING: [#def10] Pillow-12.2.0/src/libImaging/Resample.c:217:10: warning[-Wanalyzer-imprecise-fp-arithmetic]: use of floating-point arithmetic here might yield unexpected results Pillow-12.2.0/src/libImaging/Resample.c:708:1: enter_function: entry to ‘ImagingResampleInner’ Pillow-12.2.0/src/libImaging/Resample.c:729:19: call_function: calling ‘precompute_coeffs’ from ‘ImagingResampleInner’ # 215| /* coefficient buffer */ # 216| /* malloc check ok, overflow checked above */ # 217|-> kk = malloc(outSize * ksize * sizeof(double)); # 218| if (!kk) { # 219| ImagingError_MemoryError(); Error: GCC_ANALYZER_WARNING (CWE-401): [#def11] Pillow-12.2.0/src/libImaging/SgiRleDecode.c:227:8: warning[-Wanalyzer-malloc-leak]: leak of ‘calloc((long unsigned int)*c.tablen, 4)’ Pillow-12.2.0/src/libImaging/SgiRleDecode.c:171:8: branch_false: following ‘false’ branch... Pillow-12.2.0/src/libImaging/SgiRleDecode.c:178:8: branch_false: following ‘false’ branch... Pillow-12.2.0/src/libImaging/SgiRleDecode.c:182:18: branch_false: ...to here Pillow-12.2.0/src/libImaging/SgiRleDecode.c:183:8: branch_false: following ‘false’ branch... Pillow-12.2.0/src/libImaging/SgiRleDecode.c:187:16: branch_false: ...to here Pillow-12.2.0/src/libImaging/SgiRleDecode.c:194:8: branch_false: following ‘false’ branch... Pillow-12.2.0/src/libImaging/SgiRleDecode.c:199:11: branch_false: ...to here Pillow-12.2.0/src/libImaging/SgiRleDecode.c:200:8: branch_false: following ‘false’ branch (when ‘ptr’ is non-NULL)... Pillow-12.2.0/src/libImaging/SgiRleDecode.c:204:9: branch_false: ...to here Pillow-12.2.0/src/libImaging/SgiRleDecode.c:204:8: branch_false: following ‘false’ branch... Pillow-12.2.0/src/libImaging/SgiRleDecode.c:205:52: branch_false: ...to here Pillow-12.2.0/src/libImaging/SgiRleDecode.c:204:9: branch_false: following ‘false’ branch... Pillow-12.2.0/src/libImaging/SgiRleDecode.c:212:5: branch_false: ...to here Pillow-12.2.0/src/libImaging/SgiRleDecode.c:225:19: acquire_memory: allocated here Pillow-12.2.0/src/libImaging/SgiRleDecode.c:227:8: danger: ‘calloc((long unsigned int)*c.tablen, 4)’ leaks here; was allocated at [(15)](sarif:/runs/0/results/0/codeFlows/0/threadFlows/0/locations/14) # 225| c->starttab = calloc(c->tablen, sizeof(UINT32)); # 226| c->lengthtab = calloc(c->tablen, sizeof(UINT32)); # 227|-> if (!state->buffer || !c->starttab || !c->lengthtab) { # 228| err = IMAGING_CODEC_MEMORY; # 229| goto sgi_finish_decode; Error: GCC_ANALYZER_WARNING (CWE-401): [#def12] Pillow-12.2.0/src/libImaging/SgiRleDecode.c:227:9: warning[-Wanalyzer-malloc-leak]: leak of ‘calloc((long unsigned int)*c.tablen, 4)’ Pillow-12.2.0/src/libImaging/SgiRleDecode.c:171:8: branch_false: following ‘false’ branch... Pillow-12.2.0/src/libImaging/SgiRleDecode.c:178:8: branch_false: following ‘false’ branch... Pillow-12.2.0/src/libImaging/SgiRleDecode.c:182:18: branch_false: ...to here Pillow-12.2.0/src/libImaging/SgiRleDecode.c:183:8: branch_false: following ‘false’ branch... Pillow-12.2.0/src/libImaging/SgiRleDecode.c:187:16: branch_false: ...to here Pillow-12.2.0/src/libImaging/SgiRleDecode.c:194:8: branch_false: following ‘false’ branch... Pillow-12.2.0/src/libImaging/SgiRleDecode.c:199:11: branch_false: ...to here Pillow-12.2.0/src/libImaging/SgiRleDecode.c:200:8: branch_false: following ‘false’ branch (when ‘ptr’ is non-NULL)... Pillow-12.2.0/src/libImaging/SgiRleDecode.c:204:9: branch_false: ...to here Pillow-12.2.0/src/libImaging/SgiRleDecode.c:204:8: branch_false: following ‘false’ branch... Pillow-12.2.0/src/libImaging/SgiRleDecode.c:205:52: branch_false: ...to here Pillow-12.2.0/src/libImaging/SgiRleDecode.c:204:9: branch_false: following ‘false’ branch... Pillow-12.2.0/src/libImaging/SgiRleDecode.c:212:5: branch_false: ...to here Pillow-12.2.0/src/libImaging/SgiRleDecode.c:226:20: acquire_memory: allocated here Pillow-12.2.0/src/libImaging/SgiRleDecode.c:227:8: branch_false: following ‘false’ branch... Pillow-12.2.0/src/libImaging/SgiRleDecode.c:227:9: branch_false: ...to here Pillow-12.2.0/src/libImaging/SgiRleDecode.c:227:9: danger: ‘calloc((long unsigned int)*c.tablen, 4)’ leaks here; was allocated at [(15)](sarif:/runs/0/results/1/codeFlows/0/threadFlows/0/locations/14) # 225| c->starttab = calloc(c->tablen, sizeof(UINT32)); # 226| c->lengthtab = calloc(c->tablen, sizeof(UINT32)); # 227|-> if (!state->buffer || !c->starttab || !c->lengthtab) { # 228| err = IMAGING_CODEC_MEMORY; # 229| goto sgi_finish_decode; Error: GCC_ANALYZER_WARNING (CWE-401): [#def13] Pillow-12.2.0/src/libImaging/SgiRleDecode.c:227:9: warning[-Wanalyzer-malloc-leak]: leak of ‘calloc((long unsigned int)*c.tablen, 4)’ Pillow-12.2.0/src/libImaging/SgiRleDecode.c:171:8: branch_false: following ‘false’ branch... Pillow-12.2.0/src/libImaging/SgiRleDecode.c:178:8: branch_false: following ‘false’ branch... Pillow-12.2.0/src/libImaging/SgiRleDecode.c:182:18: branch_false: ...to here Pillow-12.2.0/src/libImaging/SgiRleDecode.c:183:8: branch_false: following ‘false’ branch... Pillow-12.2.0/src/libImaging/SgiRleDecode.c:187:16: branch_false: ...to here Pillow-12.2.0/src/libImaging/SgiRleDecode.c:194:8: branch_false: following ‘false’ branch... Pillow-12.2.0/src/libImaging/SgiRleDecode.c:199:11: branch_false: ...to here Pillow-12.2.0/src/libImaging/SgiRleDecode.c:200:8: branch_false: following ‘false’ branch (when ‘ptr’ is non-NULL)... Pillow-12.2.0/src/libImaging/SgiRleDecode.c:204:9: branch_false: ...to here Pillow-12.2.0/src/libImaging/SgiRleDecode.c:204:8: branch_false: following ‘false’ branch... Pillow-12.2.0/src/libImaging/SgiRleDecode.c:205:52: branch_false: ...to here Pillow-12.2.0/src/libImaging/SgiRleDecode.c:204:9: branch_false: following ‘false’ branch... Pillow-12.2.0/src/libImaging/SgiRleDecode.c:212:5: branch_false: ...to here Pillow-12.2.0/src/libImaging/SgiRleDecode.c:225:19: acquire_memory: allocated here Pillow-12.2.0/src/libImaging/SgiRleDecode.c:227:8: branch_false: following ‘false’ branch... Pillow-12.2.0/src/libImaging/SgiRleDecode.c:227:9: branch_false: ...to here Pillow-12.2.0/src/libImaging/SgiRleDecode.c:227:9: branch_false: following ‘false’ branch... Pillow-12.2.0/src/libImaging/SgiRleDecode.c:227:9: branch_false: ...to here Pillow-12.2.0/src/libImaging/SgiRleDecode.c:227:9: danger: ‘calloc((long unsigned int)*c.tablen, 4)’ leaks here; was allocated at [(15)](sarif:/runs/0/results/2/codeFlows/0/threadFlows/0/locations/14) # 225| c->starttab = calloc(c->tablen, sizeof(UINT32)); # 226| c->lengthtab = calloc(c->tablen, sizeof(UINT32)); # 227|-> if (!state->buffer || !c->starttab || !c->lengthtab) { # 228| err = IMAGING_CODEC_MEMORY; # 229| goto sgi_finish_decode; Error: GCC_ANALYZER_WARNING (CWE-401): [#def14] Pillow-12.2.0/src/libImaging/SgiRleDecode.c:232:44: warning[-Wanalyzer-malloc-leak]: leak of ‘calloc((long unsigned int)*c.tablen, 4)’ Pillow-12.2.0/src/libImaging/SgiRleDecode.c:171:8: branch_false: following ‘false’ branch... Pillow-12.2.0/src/libImaging/SgiRleDecode.c:178:8: branch_false: following ‘false’ branch... Pillow-12.2.0/src/libImaging/SgiRleDecode.c:182:18: branch_false: ...to here Pillow-12.2.0/src/libImaging/SgiRleDecode.c:183:8: branch_false: following ‘false’ branch... Pillow-12.2.0/src/libImaging/SgiRleDecode.c:187:16: branch_false: ...to here Pillow-12.2.0/src/libImaging/SgiRleDecode.c:194:8: branch_false: following ‘false’ branch... Pillow-12.2.0/src/libImaging/SgiRleDecode.c:199:11: branch_false: ...to here Pillow-12.2.0/src/libImaging/SgiRleDecode.c:200:8: branch_false: following ‘false’ branch (when ‘ptr’ is non-NULL)... Pillow-12.2.0/src/libImaging/SgiRleDecode.c:204:9: branch_false: ...to here Pillow-12.2.0/src/libImaging/SgiRleDecode.c:204:8: branch_false: following ‘false’ branch... Pillow-12.2.0/src/libImaging/SgiRleDecode.c:205:52: branch_false: ...to here Pillow-12.2.0/src/libImaging/SgiRleDecode.c:204:9: branch_false: following ‘false’ branch... Pillow-12.2.0/src/libImaging/SgiRleDecode.c:212:5: branch_false: ...to here Pillow-12.2.0/src/libImaging/SgiRleDecode.c:225:19: acquire_memory: allocated here Pillow-12.2.0/src/libImaging/SgiRleDecode.c:227:8: branch_false: following ‘false’ branch... Pillow-12.2.0/src/libImaging/SgiRleDecode.c:227:9: branch_false: ...to here Pillow-12.2.0/src/libImaging/SgiRleDecode.c:227:9: branch_false: following ‘false’ branch... Pillow-12.2.0/src/libImaging/SgiRleDecode.c:232:44: danger: ‘calloc((long unsigned int)*c.tablen, 4)’ leaks here; was allocated at [(15)](sarif:/runs/0/results/3/codeFlows/0/threadFlows/0/locations/14) # 230| } # 231| /* populate offsets table */ # 232|-> for (c->tabindex = 0, c->bufindex = 0; c->tabindex < c->tablen; # 233| c->tabindex++, c->bufindex += 4) { # 234| read4B(&c->starttab[c->tabindex], &ptr[c->bufindex]); Error: GCC_ANALYZER_WARNING (CWE-401): [#def15] Pillow-12.2.0/src/libImaging/Storage.c:260:12: warning[-Wanalyzer-malloc-leak]: leak of ‘block.ptr’ Pillow-12.2.0/src/libImaging/Storage.c:640:1: enter_function: entry to ‘ImagingNewDirty’ Pillow-12.2.0/src/libImaging/Storage.c:644:12: call_function: calling ‘ImagingNewInternal’ from ‘ImagingNewDirty’ # 258| Imaging # 259| ImagingNewPrologue(const ModeID mode, int xsize, int ysize) { # 260|-> return ImagingNewPrologueSubtype( # 261| mode, xsize, ysize, sizeof(struct ImagingMemoryInstance) # 262| ); Error: GCC_ANALYZER_WARNING (CWE-401): [#def16] Pillow-12.2.0/src/libImaging/Storage.c:411:1: warning[-Wanalyzer-malloc-leak]: leak of ‘block.ptr’ Pillow-12.2.0/src/libImaging/Storage.c:596:1: enter_function: entry to ‘ImagingNewInternal’ Pillow-12.2.0/src/libImaging/Storage.c:604:8: branch_false: following ‘false’ branch... Pillow-12.2.0/src/libImaging/Storage.c:609:19: branch_false: ...to here Pillow-12.2.0/src/libImaging/Storage.c:609:19: call_function: calling ‘ImagingAllocateArray’ from ‘ImagingNewInternal’ # 409| arena->stats_freed_blocks += 1; # 410| } # 411|-> } # 412| # 413| static void
| analyzer-version-clippy | 1.95.0 |
| analyzer-version-cppcheck | 2.20.0 |
| analyzer-version-gcc | 16.1.1 |
| analyzer-version-gcc-analyzer | 16.1.1 |
| analyzer-version-shellcheck | 0.11.0 |
| analyzer-version-unicontrol | 0.0.2 |
| enabled-plugins | clippy, cppcheck, gcc, shellcheck, unicontrol |
| exit-code | 0 |
| host | ip-172-16-1-147.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.20260524.213755.g3c6d0be.main-1.el9.noarch |
| mock-config | fedora-rawhide-x86_64 |
| project-name | python-pillow-12.2.0-1.fc45 |
| store-results-to | /tmp/tmpdlwcgr72/python-pillow-12.2.0-1.fc45.tar.xz |
| time-created | 2026-06-01 16:11:55 |
| time-finished | 2026-06-01 16:15:19 |
| tool | csmock |
| tool-args | '/usr/bin/csmock' '-r' 'fedora-rawhide-x86_64' '-t' 'shellcheck,cppcheck,clippy,unicontrol,gcc' '-o' '/tmp/tmpdlwcgr72/python-pillow-12.2.0-1.fc45.tar.xz' '--gcc-analyze' '--unicontrol-notests' '--unicontrol-bidi-only' '--install' 'pam' '--gcc-analyzer-bin=/usr/bin/gcc' '/tmp/tmpdlwcgr72/python-pillow-12.2.0-1.fc45.src.rpm' |
| tool-version | csmock-3.8.5.20260529.133039.g6f3b5c6-1.el9 |