Error: COMPILER_WARNING: [#def1] gmp-6.3.0/conftest.s: scope_hint: Assembler messages gmp-6.3.0/conftest.s:2: Error: no such instruction: `somelabel' Error: COMPILER_WARNING: [#def2] gmp-6.3.0/conftest.s: scope_hint: Assembler messages gmp-6.3.0/conftest.s:3: Error: unknown pseudo-op: `.def' Error: COMPILER_WARNING: [#def3] gmp-6.3.0/conftest.s:4: Error: unknown pseudo-op: `.scl' Error: COMPILER_WARNING: [#def4] gmp-6.3.0/conftest.s:5: Error: Missing symbol name in directive Error: COMPILER_WARNING: [#def5] gmp-6.3.0/conftest.s:5: Error: unrecognized symbol type "32" Error: COMPILER_WARNING: [#def6] gmp-6.3.0/conftest.s:6: Error: unknown pseudo-op: `.endef' Error: COMPILER_WARNING (CWE-1164): [#def7] gmp-6.3.0/cxx/ismpf.cc: scope_hint: In function 'std::istream& operator>>(std::istream&, mpf_ptr)' gmp-6.3.0/cxx/ismpf.cc:139:5: warning[-Wunused-label]: label 'fail' defined but not used # 139 | fail: # | ^~~~ # 137| else # 138| { # 139|-> fail: # 140| i.setstate(ios::failbit); // read failed # 141| } Error: COMPILER_WARNING: [#def8] gmp-6.3.0/cxx/osdoprnti.cc: scope_hint: In function 'std::ostream& __gmp_doprnt_integer_ostream(std::ostream&, doprnt_params_t*, char*)' gmp-6.3.0/cxx/osdoprnti.cc:54:9: warning[-Wunused-but-set-variable=]: variable 'ret' set but not used # 54 | int ret; # | ^~~ # 52| struct gmp_asprintf_t d; # 53| char *result; # 54|-> int ret; # 55| # 56| /* don't show leading zeros the way printf does */ Error: COMPILER_WARNING: [#def9] gmp-6.3.0/cxx/osmpf.cc: scope_hint: In function 'std::ostream& operator<<(std::ostream&, mpf_srcptr)' gmp-6.3.0/cxx/osmpf.cc:51:9: warning[-Wunused-but-set-variable=]: variable 'ret' set but not used # 51 | int ret; # | ^~~ # 49| struct gmp_asprintf_t d; # 50| char *result; # 51|-> int ret; # 52| # 53| __gmp_doprnt_params_from_ios (¶m, o); Error: COMPILER_WARNING (CWE-563): [#def10] gmp-6.3.0/extract-dbl.c: scope_hint: In function '__gmp_extract_double' gmp-6.3.0/extract-dbl.c:53:21: warning[-Wunused-variable]: unused variable 'manh' # 53 | unsigned long int manh, manl; # | ^~~~ # 51| #else # 52| #define BITS_PER_PART GMP_LIMB_BITS # 53|-> unsigned long int manh, manl; # 54| #endif # 55| Error: GCC_ANALYZER_WARNING (CWE-401): [#def11] gmp-6.3.0/gen-fib.c:77:1: warning[-Wanalyzer-malloc-leak]: leak of ‘limit[0]._mp_d’ gmp-6.3.0/gen-fib.c:120:1: enter_function: entry to ‘main’ gmp-6.3.0/gen-fib.c:124:6: branch_false: following ‘false’ branch (when ‘argc == 4’)... gmp-6.3.0/gen-fib.c:130:25: branch_false: ...to here gmp-6.3.0/gen-fib.c:133:6: branch_false: following ‘false’ branch (when ‘limb_bits > 0’)... gmp-6.3.0/gen-fib.c:133:7: branch_false: ...to here gmp-6.3.0/gen-fib.c:133:7: branch_false: following ‘false’ branch (when ‘nail_bits >= 0’)... gmp-6.3.0/gen-fib.c:133:7: branch_false: ...to here gmp-6.3.0/gen-fib.c:133:7: branch_false: following ‘false’ branch (when ‘nail_bits < limb_bits’)... gmp-6.3.0/gen-fib.c:141:3: branch_false: ...to here gmp-6.3.0/gen-fib.c:143:3: call_function: calling ‘generate’ from ‘main’ # 75| # 76| mpz_clear (limit); # 77|-> } # 78| # 79| Error: COMPILER_WARNING (CWE-563): [#def12] gmp-6.3.0/mpn/generic/toom_interpolate_5pts.c:38: included_from: Included from here. gmp-6.3.0/mpn/generic/toom_interpolate_5pts.c: scope_hint: In function '__gmpn_toom_interpolate_5pts' gmp-6.3.0/gmp-impl.h:1723:6: warning[-Wunused-value]: value computed is not used # 1723 | (3 & mpn_bdiv_dbm1 (dst, src, size, __GMP_CAST (mp_limb_t, GMP_NUMB_MASK / 3))) # | ^ gmp-6.3.0/gmp-impl.h:2525:33: note: in definition of macro 'ASSERT_NOCARRY' # 2525 | #define ASSERT_NOCARRY(expr) (expr) # | ^~~~ gmp-6.3.0/mpn/generic/toom_interpolate_5pts.c:70:19: note: in expansion of macro 'mpn_divexact_by3' # 70 | ASSERT_NOCARRY (mpn_divexact_by3 (v2, v2, kk1)); /* v2 <- v2 / 3 */ # | ^~~~~~~~~~~~~~~~ # 1721| #undef mpn_divexact_by3 # 1722| #define mpn_divexact_by3(dst,src,size) \ # 1723|-> (3 & mpn_bdiv_dbm1 (dst, src, size, __GMP_CAST (mp_limb_t, GMP_NUMB_MASK / 3))) # 1724| /* override mpn_divexact_by3c defined in gmp.h */ # 1725| /* Error: COMPILER_WARNING (CWE-563): [#def13] gmp-6.3.0/gmp-impl.h:1734:6: warning[-Wunused-value]: value computed is not used # 1734 | (7 & 3 * mpn_bdiv_dbm1 (dst, src, size, __GMP_CAST (mp_limb_t, GMP_NUMB_MASK / 5))) # | ~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ gmp-6.3.0/mpn/generic/mulmod_bknp1.c:337:5: note: in expansion of macro 'mpn_divexact_by5' # 337 | mpn_divexact_by5 (tp, tp, n + 1); # | ^~~~~~~~~~~~~~~~ # 1732| #if GMP_NUMB_BITS % 4 == 0 # 1733| #define mpn_divexact_by5(dst,src,size) \ # 1734|-> (7 & 3 * mpn_bdiv_dbm1 (dst, src, size, __GMP_CAST (mp_limb_t, GMP_NUMB_MASK / 5))) # 1735| #endif # 1736| Error: COMPILER_WARNING (CWE-563): [#def14] gmp-6.3.0/gmp-impl.h:1759:7: warning[-Wunused-value]: value computed is not used # 1759 | (15 & 1 * mpn_bdiv_dbm1 (dst, src, size, __GMP_CAST (mp_limb_t, GMP_NUMB_MASK / 15))) # | ~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ gmp-6.3.0/mpn/generic/toom_interpolate_7pts.c:212:3: note: in expansion of macro 'mpn_divexact_by15' # 212 | mpn_divexact_by15 (w1, w1, m); # | ^~~~~~~~~~~~~~~~~ # 1757| #if GMP_NUMB_BITS % 4 == 0 # 1758| #define mpn_divexact_by15(dst,src,size) \ # 1759|-> (15 & 1 * mpn_bdiv_dbm1 (dst, src, size, __GMP_CAST (mp_limb_t, GMP_NUMB_MASK / 15))) # 1760| #endif # 1761| Error: COMPILER_WARNING (CWE-563): [#def15] gmp-6.3.0/gmp-impl.h:1764:7: warning[-Wunused-value]: value computed is not used # 1764 | (31 & 15 * mpn_bdiv_dbm1 (dst, src, size, __GMP_CAST (mp_limb_t, GMP_NUMB_MASK / 17))) # | ~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ gmp-6.3.0/mpn/generic/mulmod_bknp1.c:348:5: note: in expansion of macro 'mpn_divexact_by17' # 348 | mpn_divexact_by17 (tp, tp, n + 1); # | ^~~~~~~~~~~~~~~~~ # 1762| #if GMP_NUMB_BITS % 8 == 0 # 1763| #define mpn_divexact_by17(dst,src,size) \ # 1764|-> (31 & 15 * mpn_bdiv_dbm1 (dst, src, size, __GMP_CAST (mp_limb_t, GMP_NUMB_MASK / 17))) # 1765| #endif # 1766| Error: GCC_ANALYZER_WARNING (CWE-471): [#def16] gmp-6.3.0/mini-gmp/mini-gmp.c:458:7: warning[-Wanalyzer-write-to-const]: write to ‘const’ object ‘dummy_limb’ gmp-6.3.0/bootstrap.c:126:1: enter_function: entry to ‘mpz_invert_ui_2exp’ gmp-6.3.0/bootstrap.c:130:3: call_function: calling ‘mpz_init_set_ui’ from ‘mpz_invert_ui_2exp’ gmp-6.3.0/bootstrap.c:130:3: return_function: returning to ‘mpz_invert_ui_2exp’ from ‘mpz_init_set_ui’ gmp-6.3.0/bootstrap.c:131:3: call_function: calling ‘mpz_invert_2exp’ from ‘mpz_invert_ui_2exp’ # 456| /* Carry out */ # 457| b = (r < b); # 458|-> rp[i] = r; # 459| } # 460| while (++i < n); Error: GCC_ANALYZER_WARNING (CWE-401): [#def17] gmp-6.3.0/mini-gmp/mini-gmp.c:1470:5: warning[-Wanalyzer-malloc-leak]: leak of ‘limit[0]._mp_d’ gmp-6.3.0/gen-fib.c:120:1: enter_function: entry to ‘main’ gmp-6.3.0/gen-fib.c:124:6: branch_false: following ‘false’ branch (when ‘argc == 4’)... gmp-6.3.0/gen-fib.c:130:25: branch_false: ...to here gmp-6.3.0/gen-fib.c:133:6: branch_false: following ‘false’ branch (when ‘limb_bits > 0’)... gmp-6.3.0/gen-fib.c:133:7: branch_false: ...to here gmp-6.3.0/gen-fib.c:133:7: branch_false: following ‘false’ branch (when ‘nail_bits >= 0’)... gmp-6.3.0/gen-fib.c:133:7: branch_false: ...to here gmp-6.3.0/gen-fib.c:133:7: branch_false: following ‘false’ branch (when ‘nail_bits < limb_bits’)... gmp-6.3.0/gen-fib.c:141:3: branch_false: ...to here gmp-6.3.0/gen-fib.c:143:3: call_function: calling ‘generate’ from ‘main’ # 1468| r->_mp_d = gmp_realloc_limbs (r->_mp_d, r->_mp_alloc, size); # 1469| else # 1470|-> r->_mp_d = gmp_alloc_limbs (size); # 1471| r->_mp_alloc = size; # 1472| Error: GCC_ANALYZER_WARNING (CWE-457): [#def18] gmp-6.3.0/mini-gmp/mini-gmp.c:3691:3: warning[-Wanalyzer-use-of-uninitialized-value]: use of uninitialized value ‘*<unknown>’ gmp-6.3.0/gen-fib.c:120:1: enter_function: entry to ‘main’ gmp-6.3.0/gen-fib.c:124:6: branch_false: following ‘false’ branch (when ‘argc == 4’)... gmp-6.3.0/gen-fib.c:130:25: branch_false: ...to here gmp-6.3.0/gen-fib.c:133:6: branch_false: following ‘false’ branch (when ‘limb_bits > 0’)... gmp-6.3.0/gen-fib.c:133:7: branch_false: ...to here gmp-6.3.0/gen-fib.c:133:7: branch_false: following ‘false’ branch (when ‘nail_bits >= 0’)... gmp-6.3.0/gen-fib.c:133:7: branch_false: ...to here gmp-6.3.0/gen-fib.c:133:7: branch_false: following ‘false’ branch (when ‘nail_bits < limb_bits’)... gmp-6.3.0/gen-fib.c:141:3: branch_false: ...to here gmp-6.3.0/gen-fib.c:143:3: call_function: calling ‘generate’ from ‘main’ # 3689| # 3690| shift = bit_index % GMP_LIMB_BITS; # 3691|-> w = d->_mp_d[limb_index]; # 3692| bit = (w >> shift) & 1; # 3693| Error: GCC_ANALYZER_WARNING (CWE-404): [#def19] gmp-6.3.0/mpf/clears.c:43:7: warning[-Wanalyzer-va-list-leak]: missing call to 'va_end' gmp-6.3.0/mpf/clears.c:39:3: acquire_resource: 'va_start' called here gmp-6.3.0/mpf/clears.c:43:7: throw: if the called function throws an exception... gmp-6.3.0/mpf/clears.c:43:7: danger: missing call to 'va_end' to match 'va_start' at [(1)](sarif:/runs/0/results/0/codeFlows/0/threadFlows/0/locations/0) # 41| do # 42| { # 43|-> __GMP_FREE_FUNC_LIMBS (PTR(x), PREC(x) + 1); # 44| x = va_arg (ap, mpf_ptr); # 45| } Error: GCC_ANALYZER_WARNING (CWE-404): [#def20] gmp-6.3.0/mpf/inits.c:43:7: warning[-Wanalyzer-va-list-leak]: missing call to 'va_end' gmp-6.3.0/mpf/inits.c:39:3: acquire_resource: 'va_start' called here gmp-6.3.0/mpf/inits.c:43:7: throw: if '__gmpf_init' throws an exception... gmp-6.3.0/mpf/inits.c:43:7: danger: missing call to 'va_end' to match 'va_start' at [(1)](sarif:/runs/0/results/0/codeFlows/0/threadFlows/0/locations/0) # 41| do # 42| { # 43|-> mpf_init (x); # 44| x = va_arg (ap, mpf_ptr); # 45| } Error: COMPILER_WARNING (CWE-457): [#def21] gmp-6.3.0/mpn/generic/gcdext.c: scope_hint: In function '__gmpn_gcdext' gmp-6.3.0/mpn/generic/gcdext.c:303:50: warning[-Wmaybe-uninitialized]: 'matrix_scratch' may be used uninitialized # 303 | nn = mpn_hgcd (ap + p, bp + p, n - p, &M, tp + matrix_scratch); # | ^ gmp-6.3.0/mpn/generic/gcdext.c:203:13: note: 'matrix_scratch' was declared here # 203 | mp_size_t matrix_scratch; # | ^~~~~~~~~~~~~~ # 301| # 302| mpn_hgcd_matrix_init (&M, n - p, tp); # 303|-> nn = mpn_hgcd (ap + p, bp + p, n - p, &M, tp + matrix_scratch); # 304| if (nn > 0) # 305| { Error: COMPILER_WARNING: [#def22] gmp-6.3.0/mpn/generic/invertappr.c: scope_hint: In function '__gmpn_ni_invertappr' gmp-6.3.0/mpn/generic/invertappr.c:230:21: warning[-Wunused-but-set-variable=]: variable 'chk' set but not used # 230 | mp_limb_t chk; # | ^~~ # 228| if (cy++) { # 229| if (mpn_cmp (xp, dp - n, n) > 0) { # 230|-> mp_limb_t chk; # 231| chk = mpn_sublsh1_n (xp, xp, dp - n, n); # 232| ASSERT (chk == xp[n]); Error: COMPILER_WARNING: [#def23] gmp-6.3.0/mpn/generic/matrix22_mul1_inverse_vector.c:44:13: warning[-Wunused-but-set-variable=]: variable 'h0' set but not used # 44 | mp_limb_t h0, h1; # | ^~ # 42| mp_ptr rp, mp_srcptr ap, mp_ptr bp, mp_size_t n) # 43| { # 44|-> mp_limb_t h0, h1; # 45| # 46| /* Compute (r;b) <-- (u11 a - u01 b; -u10 a + u00 b) as Error: COMPILER_WARNING: [#def24] gmp-6.3.0/mpn/generic/matrix22_mul1_inverse_vector.c: scope_hint: In function '__gmpn_matrix22_mul1_inverse_vector' gmp-6.3.0/mpn/generic/matrix22_mul1_inverse_vector.c:44:17: warning[-Wunused-but-set-variable=]: variable 'h1' set but not used # 44 | mp_limb_t h0, h1; # | ^~ # 42| mp_ptr rp, mp_srcptr ap, mp_ptr bp, mp_size_t n) # 43| { # 44|-> mp_limb_t h0, h1; # 45| # 46| /* Compute (r;b) <-- (u11 a - u01 b; -u10 a + u00 b) as Error: COMPILER_WARNING (CWE-457): [#def25] gmp-6.3.0/mpn/generic/remove.c: scope_hint: In function '__gmpn_remove' gmp-6.3.0/mpn/generic/remove.c:141:12: warning[-Wmaybe-uninitialized]: 'np' may be used uninitialized # 141 | np += pn; # | ~~~^~~~~ gmp-6.3.0/mpn/generic/remove.c:88:18: note: 'np' was declared here # 88 | mp_ptr tp, qp, np, qp2; # | ^~ # 139| np = TMP_ALLOC_LIMBS (qn + LOG); /* powers of V */ # 140| else # 141|-> np += pn; # 142| # 143| mpn_sqr (np, pp, pn); Error: COMPILER_WARNING: [#def26] gmp-6.3.0/mpn/generic/rootrem.c: scope_hint: In function 'mpn_rootrem_internal' gmp-6.3.0/mpn/generic/rootrem.c:219:22: warning[-Wunused-but-set-variable=]: variable 'c' set but not used # 219 | unsigned ulz, snb, c, logk; # | ^ # 217| int ni; # 218| int perf_pow; # 219|-> unsigned ulz, snb, c, logk; # 220| TMP_DECL; # 221| Error: COMPILER_WARNING (CWE-457): [#def27] gmp-6.3.0/mpn/generic/rootrem.c:514:10: warning[-Wmaybe-uninitialized]: 'rn' may be used uninitialized # 514 | return rn; # | ^~ gmp-6.3.0/mpn/generic/rootrem.c:211:17: note: 'rn' was declared here # 211 | mp_size_t qn, rn, sn, wn, nl, bn; # | ^~ # 512| # 513| TMP_FREE; # 514|-> return rn; # 515| } Error: COMPILER_WARNING (CWE-563): [#def28] gmp-6.3.0/mpn/generic/sec_div.c: scope_hint: In function '__gmpn_sec_div_r' gmp-6.3.0/mpn/generic/sec_div.c:86:17: warning[-Wunused-variable]: unused variable 'qh' # 86 | mp_limb_t qh, cy; # | ^~ # 84| if (cnt != 0) # 85| { # 86|-> mp_limb_t qh, cy; # 87| mp_ptr np2, dp2; # 88| dp2 = tp; /* dn limbs */ Error: COMPILER_WARNING (CWE-563): [#def29] gmp-6.3.0/mpn/generic/toom_interpolate_12pts.c: scope_hint: In function '__gmpn_toom_interpolate_12pts' gmp-6.3.0/mpn/generic/toom_interpolate_12pts.c:137:8: warning[-Wunused-value]: value computed is not used # 137 | (255 & 1 * mpn_bdiv_dbm1 (dst, src, size, __GMP_CAST (mp_limb_t, GMP_NUMB_MASK / 255))) # | ~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ gmp-6.3.0/mpn/generic/toom_interpolate_12pts.c:268:3: note: in expansion of macro 'mpn_divexact_by255' # 268 | mpn_divexact_by255(r5, r5, n3p1); # | ^~~~~~~~~~~~~~~~~~ # 135| #if GMP_NUMB_BITS % 8 == 0 # 136| #define mpn_divexact_by255(dst,src,size) \ # 137|-> (255 & 1 * mpn_bdiv_dbm1 (dst, src, size, __GMP_CAST (mp_limb_t, GMP_NUMB_MASK / 255))) # 138| #else # 139| #if HAVE_NATIVE_mpn_pi1_bdiv_q_1 Error: GCC_ANALYZER_WARNING (CWE-457): [#def30] gmp-6.3.0/mpn/rootrem.c:240:14: warning[-Wanalyzer-use-of-uninitialized-value]: use of uninitialized value '<unknown>' gmp-6.3.0/mpn/rootrem.c:229:6: branch_false: following 'false' branch (when 'unb >= k')... gmp-6.3.0/mpn/rootrem.c:244:6: branch_false: ...to here gmp-6.3.0/mpn/rootrem.c:314:17: branch_false: following 'false' branch (when 'ni == 0')... gmp-6.3.0/mpn/rootrem.c:484:6: branch_false: ...to here gmp-6.3.0/mpn/rootrem.c:484:6: branch_false: following 'false' branch... gmp-6.3.0/mpn/rootrem.c:513:3: branch_false: following 'false' branch... gmp-6.3.0/mpn/rootrem.c:240:14: branch_false: ...to here gmp-6.3.0/mpn/rootrem.c:240:14: danger: use of uninitialized value '<unknown>' here # 238| if we demand u to be normalized */ # 239| } # 240|-> return un; # 241| } # 242| /* if (unb - k < k/2 + k/16) // root is 2 */ Error: GCC_ANALYZER_WARNING: [#def31] gmp-6.3.0/mpn/rootrem.c:300:3: warning[-Wanalyzer-imprecise-fp-arithmetic]: use of floating-point arithmetic here might yield unexpected results gmp-6.3.0/mpn/rootrem.c:229:6: branch_false: following 'false' branch (when 'unb >= k')... gmp-6.3.0/mpn/rootrem.c:244:6: branch_false: ...to here gmp-6.3.0/mpn/rootrem.c:300:3: branch_true: following 'true' branch... gmp-6.3.0/mpn/rootrem.c:300:3: branch_true: ...to here gmp-6.3.0/mpn/rootrem.c:300:3: danger: operand '5.8499999999999996e-1' is of type 'double' # 298| 258/256 instead of 3/2 ? log2(258/256) < 1/89 < 1/64 */ # 299| #define EXTRA 2 + (mp_size_t) (0.585 * (double) k / (double) GMP_NUMB_BITS) # 300|-> TMP_ALLOC_LIMBS_3 (scratch, un + 1, /* used by mpn_div_q */ # 301| qp, un + EXTRA, /* will contain quotient and remainder # 302| of R/(k*S^(k-1)), and S^k */ Error: COMPILER_WARNING: [#def32] gmp-6.3.0/mpn/fat_addmul_2.c:10: included_from: Included from here. gmp-6.3.0/mpn/x86_64/fat/addmul_2.c:34:69: warning[-Warray-parameter=]: argument 4 of type 'const mp_limb_t[2]' {aka 'const long unsigned int[2]'} with mismatched bound # 34 | mpn_addmul_2 (mp_ptr rp, mp_srcptr up, mp_size_t n, const mp_limb_t vp[2]) # | ~~~~~~~~~~~~~~~~^~~~~ gmp-6.3.0/mpn/x86_64/fat/addmul_2.c:31: included_from: Included from here. gmp-6.3.0/gmp-impl.h:75:64: note: previously declared as 'mp_srcptr' {aka 'const long unsigned int *'} # 75 | __GMP_DECLSPEC mp_limb_t name (mp_ptr, mp_srcptr, mp_size_t, mp_srcptr) # | ^~~~~~~~~ gmp-6.3.0/fat.h:420:1: note: in expansion of macro 'DECL_addmul_2' # 420 | DECL_addmul_2 (__gmpn_addmul_2_fat); # | ^~~~~~~~~~~~~ # 32| # 33| mp_limb_t # 34|-> mpn_addmul_2 (mp_ptr rp, mp_srcptr up, mp_size_t n, const mp_limb_t vp[2]) # 35| { # 36| rp[n] = mpn_addmul_1 (rp, up, n, vp[0]); Error: GCC_ANALYZER_WARNING (CWE-404): [#def33] gmp-6.3.0/mpq/clears.c:44:9: warning[-Wanalyzer-va-list-leak]: missing call to 'va_end' gmp-6.3.0/mpq/clears.c:39:3: acquire_resource: 'va_start' called here gmp-6.3.0/mpq/clears.c:43:10: branch_true: following 'true' branch... gmp-6.3.0/mpq/clears.c:44:9: branch_true: ...to here gmp-6.3.0/mpq/clears.c:44:9: throw: if the called function throws an exception... gmp-6.3.0/mpq/clears.c:44:9: danger: missing call to 'va_end' to match 'va_start' at [(1)](sarif:/runs/0/results/0/codeFlows/0/threadFlows/0/locations/0) # 42| { # 43| if (ALLOC (NUM(x))) # 44|-> __GMP_FREE_FUNC_LIMBS (PTR(NUM(x)), ALLOC(NUM(x))); # 45| if (ALLOC (DEN(x))) # 46| __GMP_FREE_FUNC_LIMBS (PTR(DEN(x)), ALLOC(DEN(x))); Error: GCC_ANALYZER_WARNING (CWE-404): [#def34] gmp-6.3.0/mpq/clears.c:46:9: warning[-Wanalyzer-va-list-leak]: missing call to 'va_end' gmp-6.3.0/mpq/clears.c:39:3: acquire_resource: 'va_start' called here gmp-6.3.0/mpq/clears.c:45:10: branch_true: following 'true' branch... gmp-6.3.0/mpq/clears.c:46:9: branch_true: ...to here gmp-6.3.0/mpq/clears.c:46:9: throw: if the called function throws an exception... gmp-6.3.0/mpq/clears.c:46:9: danger: missing call to 'va_end' to match 'va_start' at [(1)](sarif:/runs/0/results/1/codeFlows/0/threadFlows/0/locations/0) # 44| __GMP_FREE_FUNC_LIMBS (PTR(NUM(x)), ALLOC(NUM(x))); # 45| if (ALLOC (DEN(x))) # 46|-> __GMP_FREE_FUNC_LIMBS (PTR(DEN(x)), ALLOC(DEN(x))); # 47| x = va_arg (ap, mpq_ptr); # 48| } Error: GCC_ANALYZER_WARNING (CWE-404): [#def35] gmp-6.3.0/mpq/inits.c:43:7: warning[-Wanalyzer-va-list-leak]: missing call to 'va_end' gmp-6.3.0/mpq/inits.c:39:3: acquire_resource: 'va_start' called here gmp-6.3.0/mpq/inits.c:43:7: throw: if '__gmpq_init' throws an exception... gmp-6.3.0/mpq/inits.c:43:7: danger: missing call to 'va_end' to match 'va_start' at [(1)](sarif:/runs/0/results/0/codeFlows/0/threadFlows/0/locations/0) # 41| do # 42| { # 43|-> mpq_init (x); # 44| x = va_arg (ap, mpq_ptr); # 45| } Error: GCC_ANALYZER_WARNING (CWE-404): [#def36] gmp-6.3.0/mpz/clears.c:44:9: warning[-Wanalyzer-va-list-leak]: missing call to 'va_end' gmp-6.3.0/mpz/clears.c:39:3: acquire_resource: 'va_start' called here gmp-6.3.0/mpz/clears.c:43:10: branch_true: following 'true' branch... gmp-6.3.0/mpz/clears.c:44:9: branch_true: ...to here gmp-6.3.0/mpz/clears.c:44:9: throw: if the called function throws an exception... gmp-6.3.0/mpz/clears.c:44:9: danger: missing call to 'va_end' to match 'va_start' at [(1)](sarif:/runs/0/results/0/codeFlows/0/threadFlows/0/locations/0) # 42| { # 43| if (ALLOC (x)) # 44|-> __GMP_FREE_FUNC_LIMBS (PTR (x), ALLOC (x)); # 45| x = va_arg (ap, mpz_ptr); # 46| } Error: GCC_ANALYZER_WARNING (CWE-404): [#def37] gmp-6.3.0/printf/asprintf.c:44:9: warning[-Wanalyzer-va-list-leak]: missing call to 'va_end' gmp-6.3.0/printf/asprintf.c:42:3: acquire_resource: 'va_start' called here gmp-6.3.0/printf/asprintf.c:44:9: throw: if '__gmp_vasprintf' throws an exception... gmp-6.3.0/printf/asprintf.c:44:9: danger: missing call to 'va_end' to match 'va_start' at [(1)](sarif:/runs/0/results/0/codeFlows/0/threadFlows/0/locations/0) # 42| va_start (ap, fmt); # 43| # 44|-> ret = gmp_vasprintf (result, fmt, ap); # 45| va_end (ap); # 46| return ret; Error: CPPCHECK_WARNING (CWE-664): [#def38] gmp-6.3.0/printf/doprnt.c:174: error[va_list_usedBeforeStarted]: va_list 'ap' used before va_start() was called. # 172| very small part of the total work, and we may as well keep applications # 173| out of trouble. */ # 174|-> va_copy (ap, orig_ap); # 175| # 176| /* The format string is chopped up into pieces to be passed to Error: GCC_ANALYZER_WARNING (CWE-404): [#def39] gmp-6.3.0/printf/doprnt.c:187:15: warning[-Wanalyzer-va-list-leak]: missing call to 'va_end' gmp-6.3.0/printf/doprnt.c:174:3: acquire_resource: 'va_copy' called here gmp-6.3.0/printf/doprnt.c:187:15: throw: if the called function throws an exception... gmp-6.3.0/printf/doprnt.c:187:15: danger: missing call to 'va_end' to match 'va_copy' at [(1)](sarif:/runs/0/results/0/codeFlows/0/threadFlows/0/locations/0) # 185| alloc_fmt_size += alloc_fmt_size / 3; # 186| #endif # 187|-> alloc_fmt = __GMP_ALLOCATE_FUNC_TYPE (alloc_fmt_size, char); # 188| fmt = alloc_fmt; # 189| memcpy (fmt, orig_fmt, orig_fmt_size); Error: CPPCHECK_WARNING (CWE-664): [#def40] gmp-6.3.0/printf/doprnt.c:194: error[va_list_usedBeforeStarted]: va_list 'ap' used before va_start() was called. # 192| the next output will begin, when that's done */ # 193| last_fmt = fmt; # 194|-> va_copy (last_ap, ap); # 195| # 196| for (;;) Error: CPPCHECK_WARNING (CWE-664): [#def41] gmp-6.3.0/printf/doprnt.c:194: error[va_list_usedBeforeStarted]: va_list 'last_ap' used before va_start() was called. # 192| the next output will begin, when that's done */ # 193| last_fmt = fmt; # 194|-> va_copy (last_ap, ap); # 195| # 196| for (;;) Error: GCC_ANALYZER_WARNING (CWE-404): [#def42] gmp-6.3.0/printf/doprnt.c:206:7: warning[-Wanalyzer-va-list-leak]: missing call to 'va_end' gmp-6.3.0/printf/doprnt.c:201:10: branch_false: following 'false' branch (when 'fmt' is non-NULL)... gmp-6.3.0/printf/doprnt.c:206:7: branch_false: ...to here gmp-6.3.0/printf/doprnt.c:206:7: acquire_resource: 'va_copy' called here gmp-6.3.0/printf/doprnt.c:201:10: branch_false: following 'false' branch (when 'fmt' is non-NULL)... gmp-6.3.0/printf/doprnt.c:206:7: branch_false: ...to here gmp-6.3.0/printf/doprnt.c:206:7: danger: missing call to 'va_end' to match 'va_copy' at [(4)](sarif:/runs/0/results/1/codeFlows/0/threadFlows/0/locations/3) # 204| /* this_fmt and this_ap are the current '%' sequence being considered */ # 205| this_fmt = fmt; # 206|-> va_copy (this_ap, ap); # 207| fmt++; /* skip the '%' */ # 208| Error: CPPCHECK_WARNING (CWE-664): [#def43] gmp-6.3.0/printf/doprnt.c:612: error[va_list_usedBeforeStarted]: va_list 'last_ap' used before va_start() was called. # 610| TRACE (printf ("remainder: \"%s\"\n", last_fmt)); # 611| if (*last_fmt != '\0') # 612|-> DOPRNT_FORMAT (last_fmt, last_ap); # 613| # 614| if (funs->final != NULL) Error: GCC_ANALYZER_WARNING (CWE-404): [#def44] gmp-6.3.0/printf/doprnt.c:612:5: warning[-Wanalyzer-va-list-leak]: missing call to 'va_end' gmp-6.3.0/printf/doprnt.c:194:3: acquire_resource: 'va_copy' called here gmp-6.3.0/printf/doprnt.c:201:10: branch_true: following 'true' branch (when 'fmt' is NULL)... gmp-6.3.0/printf/doprnt.c:611:7: branch_true: ...to here gmp-6.3.0/printf/doprnt.c:611:6: branch_true: following 'true' branch... gmp-6.3.0/printf/doprnt.c:612:5: branch_true: ...to here gmp-6.3.0/printf/doprnt.c:612:5: throw: if the called function throws an exception... gmp-6.3.0/printf/doprnt.c:612:5: danger: missing call to 'va_end' to match 'va_copy' at [(1)](sarif:/runs/0/results/2/codeFlows/0/threadFlows/0/locations/0) # 610| TRACE (printf ("remainder: \"%s\"\n", last_fmt)); # 611| if (*last_fmt != '\0') # 612|-> DOPRNT_FORMAT (last_fmt, last_ap); # 613| # 614| if (funs->final != NULL) Error: GCC_ANALYZER_WARNING (CWE-404): [#def45] gmp-6.3.0/printf/doprnt.c:615:9: warning[-Wanalyzer-va-list-leak]: missing call to 'va_end' gmp-6.3.0/printf/doprnt.c:201:10: branch_false: following 'false' branch (when 'fmt' is non-NULL)... gmp-6.3.0/printf/doprnt.c:206:7: branch_false: ...to here gmp-6.3.0/printf/doprnt.c:206:7: acquire_resource: 'va_copy' called here gmp-6.3.0/printf/doprnt.c:201:10: branch_true: following 'true' branch (when 'fmt' is NULL)... gmp-6.3.0/printf/doprnt.c:611:7: branch_true: ...to here gmp-6.3.0/printf/doprnt.c:611:6: branch_true: following 'true' branch... gmp-6.3.0/printf/doprnt.c:612:5: branch_true: ...to here gmp-6.3.0/printf/doprnt.c:612:5: branch_false: following 'false' branch... gmp-6.3.0/printf/doprnt.c:612:5: branch_false: ...to here gmp-6.3.0/printf/doprnt.c:614:6: branch_true: following 'true' branch... gmp-6.3.0/printf/doprnt.c:615:9: branch_true: ...to here gmp-6.3.0/printf/doprnt.c:615:9: throw: if the called function throws an exception... gmp-6.3.0/printf/doprnt.c:615:9: danger: missing call to 'va_end' to match 'va_copy' at [(4)](sarif:/runs/0/results/3/codeFlows/0/threadFlows/0/locations/3) # 613| # 614| if (funs->final != NULL) # 615|-> if ((*funs->final) (data) == -1) # 616| goto error; # 617| Error: GCC_ANALYZER_WARNING (CWE-404): [#def46] gmp-6.3.0/printf/doprnt.c:619:3: warning[-Wanalyzer-va-list-leak]: missing call to 'va_end' gmp-6.3.0/printf/doprnt.c:201:10: branch_false: following 'false' branch (when 'fmt' is non-NULL)... gmp-6.3.0/printf/doprnt.c:206:7: branch_false: ...to here gmp-6.3.0/printf/doprnt.c:206:7: acquire_resource: 'va_copy' called here gmp-6.3.0/printf/doprnt.c:201:10: branch_true: following 'true' branch (when 'fmt' is NULL)... gmp-6.3.0/printf/doprnt.c:611:7: branch_true: ...to here gmp-6.3.0/printf/doprnt.c:611:6: branch_true: following 'true' branch... gmp-6.3.0/printf/doprnt.c:612:5: branch_true: ...to here gmp-6.3.0/printf/doprnt.c:612:5: branch_false: following 'false' branch... gmp-6.3.0/printf/doprnt.c:612:5: branch_false: ...to here gmp-6.3.0/printf/doprnt.c:614:6: branch_false: following 'false' branch... gmp-6.3.0/printf/doprnt.c:618:2: branch_false: ...to here gmp-6.3.0/printf/doprnt.c:619:3: throw: if the called function throws an exception... gmp-6.3.0/printf/doprnt.c:619:3: danger: missing call to 'va_end' to match 'va_copy' at [(4)](sarif:/runs/0/results/4/codeFlows/0/threadFlows/0/locations/3) # 617| # 618| done: # 619|-> __GMP_FREE_FUNC_TYPE (alloc_fmt, alloc_fmt_size, char); # 620| return retval; # 621| Error: GCC_ANALYZER_WARNING (CWE-404): [#def47] gmp-6.3.0/printf/doprnt.c:620:10: warning[-Wanalyzer-va-list-leak]: missing call to 'va_end' gmp-6.3.0/printf/doprnt.c:201:10: branch_false: following 'false' branch (when 'fmt' is non-NULL)... gmp-6.3.0/printf/doprnt.c:206:7: branch_false: ...to here gmp-6.3.0/printf/doprnt.c:206:7: acquire_resource: 'va_copy' called here gmp-6.3.0/printf/doprnt.c:201:10: branch_true: following 'true' branch (when 'fmt' is NULL)... gmp-6.3.0/printf/doprnt.c:611:7: branch_true: ...to here gmp-6.3.0/printf/doprnt.c:611:6: branch_true: following 'true' branch... gmp-6.3.0/printf/doprnt.c:612:5: branch_true: ...to here gmp-6.3.0/printf/doprnt.c:612:5: branch_false: following 'false' branch... gmp-6.3.0/printf/doprnt.c:612:5: branch_false: ...to here gmp-6.3.0/printf/doprnt.c:614:6: branch_false: following 'false' branch... gmp-6.3.0/printf/doprnt.c:618:2: branch_false: ...to here gmp-6.3.0/printf/doprnt.c:620:10: danger: missing call to 'va_end' to match 'va_copy' at [(4)](sarif:/runs/0/results/5/codeFlows/0/threadFlows/0/locations/3) # 618| done: # 619| __GMP_FREE_FUNC_TYPE (alloc_fmt, alloc_fmt_size, char); # 620|-> return retval; # 621| # 622| error: Error: GCC_ANALYZER_WARNING (CWE-404): [#def48] gmp-6.3.0/printf/fprintf.c:45:9: warning[-Wanalyzer-va-list-leak]: missing call to 'va_end' gmp-6.3.0/printf/fprintf.c:43:3: acquire_resource: 'va_start' called here gmp-6.3.0/printf/fprintf.c:45:9: throw: if '__gmp_doprnt' throws an exception... gmp-6.3.0/printf/fprintf.c:45:9: danger: missing call to 'va_end' to match 'va_start' at [(1)](sarif:/runs/0/results/0/codeFlows/0/threadFlows/0/locations/0) # 43| va_start (ap, fmt); # 44| # 45|-> ret = __gmp_doprnt (&__gmp_fprintf_funs, fp, fmt, ap); # 46| va_end (ap); # 47| return ret; Error: GCC_ANALYZER_WARNING (CWE-404): [#def49] gmp-6.3.0/printf/obprintf.c:53:9: warning[-Wanalyzer-va-list-leak]: missing call to 'va_end' gmp-6.3.0/printf/obprintf.c:48:3: acquire_resource: 'va_start' called here gmp-6.3.0/printf/obprintf.c:53:9: throw: if '__gmp_doprnt' throws an exception... gmp-6.3.0/printf/obprintf.c:53:9: danger: missing call to 'va_end' to match 'va_start' at [(1)](sarif:/runs/0/results/0/codeFlows/0/threadFlows/0/locations/0) # 51| fmt, strlen(fmt)+1)); # 52| # 53|-> ret = __gmp_doprnt (&__gmp_obstack_printf_funs, ob, fmt, ap); # 54| va_end (ap); # 55| return ret; Error: GCC_ANALYZER_WARNING (CWE-404): [#def50] gmp-6.3.0/printf/printf.c:45:9: warning[-Wanalyzer-va-list-leak]: missing call to 'va_end' gmp-6.3.0/printf/printf.c:43:3: acquire_resource: 'va_start' called here gmp-6.3.0/printf/printf.c:45:9: throw: if '__gmp_doprnt' throws an exception... gmp-6.3.0/printf/printf.c:45:9: danger: missing call to 'va_end' to match 'va_start' at [(1)](sarif:/runs/0/results/0/codeFlows/0/threadFlows/0/locations/0) # 43| va_start (ap, fmt); # 44| # 45|-> ret = __gmp_doprnt (&__gmp_fprintf_funs, stdout, fmt, ap); # 46| va_end (ap); # 47| return ret; Error: GCC_ANALYZER_WARNING (CWE-404): [#def51] gmp-6.3.0/printf/snprintf.c:50:9: warning[-Wanalyzer-va-list-leak]: missing call to 'va_end' gmp-6.3.0/printf/snprintf.c:44:3: acquire_resource: 'va_start' called here gmp-6.3.0/printf/snprintf.c:50:9: throw: if '__gmp_doprnt' throws an exception... gmp-6.3.0/printf/snprintf.c:50:9: danger: missing call to 'va_end' to match 'va_start' at [(1)](sarif:/runs/0/results/0/codeFlows/0/threadFlows/0/locations/0) # 48| ASSERT (! MEM_OVERLAP_P (buf, size, fmt, strlen(fmt)+1)); # 49| # 50|-> ret = __gmp_doprnt (&__gmp_snprintf_funs, &d, fmt, ap); # 51| va_end (ap); # 52| return ret; Error: CPPCHECK_WARNING (CWE-664): [#def52] gmp-6.3.0/printf/snprntffuns.c:75: error[va_list_usedBeforeStarted]: va_list 'ap' used before va_start() was called. # 73| if (avail > 1) # 74| { # 75|-> va_copy (ap, orig_ap); # 76| ret = vsnprintf (d->buf, avail, fmt, ap); # 77| if (ret == -1) Error: CPPCHECK_WARNING (CWE-664): [#def53] gmp-6.3.0/printf/snprntffuns.c:76: error[va_list_usedBeforeStarted]: va_list 'ap' used before va_start() was called. # 74| { # 75| va_copy (ap, orig_ap); # 76|-> ret = vsnprintf (d->buf, avail, fmt, ap); # 77| if (ret == -1) # 78| return ret; Error: GCC_ANALYZER_WARNING (CWE-404): [#def54] gmp-6.3.0/printf/sprintf.c:48:9: warning[-Wanalyzer-va-list-leak]: missing call to 'va_end' gmp-6.3.0/printf/sprintf.c:46:3: acquire_resource: 'va_start' called here gmp-6.3.0/printf/sprintf.c:48:9: throw: if '__gmp_doprnt' throws an exception... gmp-6.3.0/printf/sprintf.c:48:9: danger: missing call to 'va_end' to match 'va_start' at [(1)](sarif:/runs/0/results/0/codeFlows/0/threadFlows/0/locations/0) # 46| va_start (ap, fmt); # 47| # 48|-> ret = __gmp_doprnt (&__gmp_sprintf_funs, &buf, fmt, ap); # 49| va_end (ap); # 50| Error: CPPCHECK_WARNING (CWE-664): [#def55] gmp-6.3.0/printf/vasprintf.c:81: error[va_list_usedBeforeStarted]: va_list 'ap' used before va_start() was called. # 79| GMP_ASPRINTF_T_NEED (d, space); # 80| space = d->alloc - d->size; # 81|-> va_copy (ap, orig_ap); # 82| ret = vsnprintf (d->buf + d->size, space, fmt, ap); # 83| if (ret == -1) Error: CPPCHECK_WARNING (CWE-664): [#def56] gmp-6.3.0/printf/vasprintf.c:82: error[va_list_usedBeforeStarted]: va_list 'ap' used before va_start() was called. # 80| space = d->alloc - d->size; # 81| va_copy (ap, orig_ap); # 82|-> ret = vsnprintf (d->buf + d->size, space, fmt, ap); # 83| if (ret == -1) # 84| { Error: GCC_ANALYZER_WARNING (CWE-404): [#def57] gmp-6.3.0/rand/rand.c:43:11: warning[-Wanalyzer-va-list-leak]: missing call to 'va_end' gmp-6.3.0/rand/rand.c:39:3: acquire_resource: 'va_start' called here gmp-6.3.0/rand/rand.c:41:3: branch_true: following 'true' branch (when 'alg == 0')... gmp-6.3.0/rand/rand.c:42:3: branch_true: ...to here gmp-6.3.0/rand/rand.c:43:11: throw: if '__gmp_randinit_lc_2exp_size' throws an exception... gmp-6.3.0/rand/rand.c:43:11: danger: missing call to 'va_end' to match 'va_start' at [(1)](sarif:/runs/0/results/0/codeFlows/0/threadFlows/0/locations/0) # 41| switch (alg) { # 42| case GMP_RAND_ALG_LC: # 43|-> if (! gmp_randinit_lc_2exp_size (rstate, va_arg (ap, unsigned long))) # 44| gmp_errno |= GMP_ERROR_INVALID_ARGUMENT; # 45| break; Error: GCC_ANALYZER_WARNING (CWE-404): [#def58] gmp-6.3.0/scanf/doscan.c:232:7: warning[-Wanalyzer-va-list-leak]: missing call to 'va_end' gmp-6.3.0/scanf/doscan.c:467:1: enter_function: entry to '__gmp_doscan' gmp-6.3.0/scanf/doscan.c:489:3: acquire_resource: 'va_copy' called here gmp-6.3.0/scanf/doscan.c:508:10: branch_false: following 'false' branch (when 'fchar != 0')... gmp-6.3.0/scanf/doscan.c:511:11: branch_false: ...to here gmp-6.3.0/scanf/doscan.c:649:25: branch_true: following 'true' branch... gmp-6.3.0/scanf/doscan.c:649:25: branch_true: ...to here gmp-6.3.0/scanf/doscan.c:649:25: call_function: calling 'gmpscan' from '__gmp_doscan' # 230| ASSERT (p->type == 'F' || p->type == 'Q' || p->type == 'Z'); # 231| # 232|-> c = (*funs->get) (data); # 233| if (c == EOF) # 234| return -2; Error: GCC_ANALYZER_WARNING (CWE-404): [#def59] gmp-6.3.0/scanf/doscan.c:242:7: warning[-Wanalyzer-va-list-leak]: missing call to 'va_end' gmp-6.3.0/scanf/doscan.c:467:1: enter_function: entry to '__gmp_doscan' gmp-6.3.0/scanf/doscan.c:489:3: acquire_resource: 'va_copy' called here gmp-6.3.0/scanf/doscan.c:508:10: branch_false: following 'false' branch (when 'fchar != 0')... gmp-6.3.0/scanf/doscan.c:511:11: branch_false: ...to here gmp-6.3.0/scanf/doscan.c:649:25: branch_true: following 'true' branch... gmp-6.3.0/scanf/doscan.c:649:25: branch_true: ...to here gmp-6.3.0/scanf/doscan.c:649:25: call_function: calling 'gmpscan' from '__gmp_doscan' # 240| base = p->base; # 241| s_alloc = S_ALLOC_STEP; # 242|-> s = __GMP_ALLOCATE_FUNC_TYPE (s_alloc, char); # 243| s_upto = 0; # 244| hexfloat = 0; Error: GCC_ANALYZER_WARNING (CWE-404): [#def60] gmp-6.3.0/scanf/doscan.c:258:7: warning[-Wanalyzer-va-list-leak]: missing call to 'va_end' gmp-6.3.0/scanf/doscan.c:467:1: enter_function: entry to '__gmp_doscan' gmp-6.3.0/scanf/doscan.c:489:3: acquire_resource: 'va_copy' called here gmp-6.3.0/scanf/doscan.c:508:10: branch_false: following 'false' branch (when 'fchar != 0')... gmp-6.3.0/scanf/doscan.c:511:11: branch_false: ...to here gmp-6.3.0/scanf/doscan.c:649:25: branch_true: following 'true' branch... gmp-6.3.0/scanf/doscan.c:649:25: branch_true: ...to here gmp-6.3.0/scanf/doscan.c:649:25: call_function: calling 'gmpscan' from '__gmp_doscan' # 256| /* don't store '+', it's not accepted by mpz_set_str etc */ # 257| get_for_sign: # 258|-> GET (c); # 259| } # 260| Error: GCC_ANALYZER_WARNING (CWE-404): [#def61] gmp-6.3.0/scanf/doscan.c:453:11: warning[-Wanalyzer-va-list-leak]: missing call to 'va_end' gmp-6.3.0/scanf/doscan.c:467:1: enter_function: entry to '__gmp_doscan' gmp-6.3.0/scanf/doscan.c:489:3: acquire_resource: 'va_copy' called here gmp-6.3.0/scanf/doscan.c:508:10: branch_false: following 'false' branch (when 'fchar != 0')... gmp-6.3.0/scanf/doscan.c:511:11: branch_false: ...to here gmp-6.3.0/scanf/doscan.c:511:10: branch_true: following 'true' branch... gmp-6.3.0/scanf/doscan.c:513:20: branch_true: ...to here gmp-6.3.0/scanf/doscan.c:513:20: call_function: calling 'skip_white' from '__gmp_doscan' # 451| do # 452| { # 453|-> c = (funs->get) (data); # 454| ret++; # 455| } Error: GCC_ANALYZER_WARNING (CWE-404): [#def62] gmp-6.3.0/scanf/doscan.c:458:3: warning[-Wanalyzer-va-list-leak]: missing call to 'va_end' gmp-6.3.0/scanf/doscan.c:467:1: enter_function: entry to '__gmp_doscan' gmp-6.3.0/scanf/doscan.c:489:3: acquire_resource: 'va_copy' called here gmp-6.3.0/scanf/doscan.c:508:10: branch_false: following 'false' branch (when 'fchar != 0')... gmp-6.3.0/scanf/doscan.c:511:11: branch_false: ...to here gmp-6.3.0/scanf/doscan.c:511:10: branch_true: following 'true' branch... gmp-6.3.0/scanf/doscan.c:513:20: branch_true: ...to here gmp-6.3.0/scanf/doscan.c:513:20: call_function: calling 'skip_white' from '__gmp_doscan' # 456| while (isspace (c)); # 457| # 458|-> (funs->unget) (c, data); # 459| ret--; # 460| Error: COMPILER_WARNING (CWE-563): [#def63] gmp-6.3.0/scanf/doscan.c: scope_hint: In function '__gmp_doscan' gmp-6.3.0/scanf/doscan.c:473:33: warning[-Wunused-variable]: unused variable 'end_fmt' # 473 | const char *fmt, *this_fmt, *end_fmt; # | ^~~~~~~ # 471| va_list ap; # 472| char *alloc_fmt; # 473|-> const char *fmt, *this_fmt, *end_fmt; # 474| size_t orig_fmt_len, alloc_fmt_size, len; # 475| int new_fields, new_chars; Error: CPPCHECK_WARNING (CWE-664): [#def64] gmp-6.3.0/scanf/doscan.c:489: error[va_list_usedBeforeStarted]: va_list 'ap' used before va_start() was called. # 487| very small part of the total work, and we may as well keep applications # 488| out of trouble. */ # 489|-> va_copy (ap, orig_ap); # 490| # 491| /* Parts of the format string are going to be copied so that a " %n" can Error: GCC_ANALYZER_WARNING (CWE-404): [#def65] gmp-6.3.0/scanf/doscan.c:498:15: warning[-Wanalyzer-va-list-leak]: missing call to 'va_end' gmp-6.3.0/scanf/doscan.c:489:3: acquire_resource: 'va_copy' called here gmp-6.3.0/scanf/doscan.c:498:15: throw: if the called function throws an exception... gmp-6.3.0/scanf/doscan.c:498:15: danger: missing call to 'va_end' to match 'va_copy' at [(1)](sarif:/runs/0/results/5/codeFlows/0/threadFlows/0/locations/0) # 496| orig_fmt_len = strlen (orig_fmt); # 497| alloc_fmt_size = orig_fmt_len + 4; # 498|-> alloc_fmt = __GMP_ALLOCATE_FUNC_TYPE (alloc_fmt_size, char); # 499| # 500| fmt = orig_fmt; Error: GCC_ANALYZER_WARNING (CWE-404): [#def66] gmp-6.3.0/scanf/doscan.c:521:15: warning[-Wanalyzer-va-list-leak]: missing call to 'va_end' gmp-6.3.0/scanf/doscan.c:489:3: acquire_resource: 'va_copy' called here gmp-6.3.0/scanf/doscan.c:508:10: branch_false: following 'false' branch (when 'fchar != 0')... gmp-6.3.0/scanf/doscan.c:511:11: branch_false: ...to here gmp-6.3.0/scanf/doscan.c:517:10: branch_true: following 'true' branch (when 'fchar != 37')... gmp-6.3.0/scanf/doscan.c:520:9: branch_true: ...to here gmp-6.3.0/scanf/doscan.c:521:15: throw: if the called function throws an exception... gmp-6.3.0/scanf/doscan.c:521:15: danger: missing call to 'va_end' to match 'va_copy' at [(1)](sarif:/runs/0/results/6/codeFlows/0/threadFlows/0/locations/0) # 519| int c; # 520| literal: # 521|-> c = (funs->get) (data); # 522| if (c != fchar) # 523| { Error: GCC_ANALYZER_WARNING (CWE-404): [#def67] gmp-6.3.0/scanf/doscan.c:524:15: warning[-Wanalyzer-va-list-leak]: missing call to 'va_end' gmp-6.3.0/scanf/doscan.c:489:3: acquire_resource: 'va_copy' called here gmp-6.3.0/scanf/doscan.c:508:10: branch_false: following 'false' branch (when 'fchar != 0')... gmp-6.3.0/scanf/doscan.c:511:11: branch_false: ...to here gmp-6.3.0/scanf/doscan.c:524:15: throw: if the called function throws an exception... gmp-6.3.0/scanf/doscan.c:524:15: danger: missing call to 'va_end' to match 'va_copy' at [(1)](sarif:/runs/0/results/7/codeFlows/0/threadFlows/0/locations/0) # 522| if (c != fchar) # 523| { # 524|-> (funs->unget) (c, data); # 525| if (c == EOF) # 526| { Error: GCC_ANALYZER_WARNING (CWE-404): [#def68] gmp-6.3.0/scanf/doscan.c:698:28: warning[-Wanalyzer-va-list-leak]: missing call to 'va_end' gmp-6.3.0/scanf/doscan.c:489:3: acquire_resource: 'va_copy' called here gmp-6.3.0/scanf/doscan.c:508:10: branch_false: following 'false' branch (when 'fchar != 0')... gmp-6.3.0/scanf/doscan.c:511:11: branch_false: ...to here gmp-6.3.0/scanf/doscan.c:691:16: branch_true: following 'true' branch... gmp-6.3.0/scanf/doscan.c:694:17: branch_true: ...to here gmp-6.3.0/scanf/doscan.c:698:28: throw: if '__gmpf_set_si' throws an exception... gmp-6.3.0/scanf/doscan.c:698:28: danger: missing call to 'va_end' to match 'va_copy' at [(1)](sarif:/runs/0/results/8/codeFlows/0/threadFlows/0/locations/0) # 696| switch (param.type) { # 697| case '\0': * (int *) p = chars; break; # 698|-> case 'F': mpf_set_si ((mpf_ptr) p, (long) chars); break; # 699| case 'H': * (char *) p = chars; break; # 700| case 'h': * (short *) p = chars; break; Error: GCC_ANALYZER_WARNING (CWE-404): [#def69] gmp-6.3.0/scanf/doscan.c:719:28: warning[-Wanalyzer-va-list-leak]: missing call to 'va_end' gmp-6.3.0/scanf/doscan.c:489:3: acquire_resource: 'va_copy' called here gmp-6.3.0/scanf/doscan.c:508:10: branch_false: following 'false' branch (when 'fchar != 0')... gmp-6.3.0/scanf/doscan.c:511:11: branch_false: ...to here gmp-6.3.0/scanf/doscan.c:691:16: branch_true: following 'true' branch... gmp-6.3.0/scanf/doscan.c:694:17: branch_true: ...to here gmp-6.3.0/scanf/doscan.c:719:28: throw: if '__gmpq_set_si' throws an exception... gmp-6.3.0/scanf/doscan.c:719:28: danger: missing call to 'va_end' to match 'va_copy' at [(1)](sarif:/runs/0/results/9/codeFlows/0/threadFlows/0/locations/0) # 717| case 'L': ASSERT_FAIL (long long not available); break; # 718| #endif # 719|-> case 'Q': mpq_set_si ((mpq_ptr) p, (long) chars, 1L); break; # 720| #if HAVE_PTRDIFF_T # 721| case 't': * (ptrdiff_t *) p = chars; break; Error: GCC_ANALYZER_WARNING (CWE-404): [#def70] gmp-6.3.0/scanf/doscan.c:726:28: warning[-Wanalyzer-va-list-leak]: missing call to 'va_end' gmp-6.3.0/scanf/doscan.c:489:3: acquire_resource: 'va_copy' called here gmp-6.3.0/scanf/doscan.c:508:10: branch_false: following 'false' branch (when 'fchar != 0')... gmp-6.3.0/scanf/doscan.c:511:11: branch_false: ...to here gmp-6.3.0/scanf/doscan.c:691:16: branch_true: following 'true' branch... gmp-6.3.0/scanf/doscan.c:694:17: branch_true: ...to here gmp-6.3.0/scanf/doscan.c:726:28: throw: if '__gmpz_set_si' throws an exception... gmp-6.3.0/scanf/doscan.c:726:28: danger: missing call to 'va_end' to match 'va_copy' at [(1)](sarif:/runs/0/results/10/codeFlows/0/threadFlows/0/locations/0) # 724| #endif # 725| case 'z': * (size_t *) p = chars; break; # 726|-> case 'Z': mpz_set_si ((mpz_ptr) p, (long) chars); break; # 727| default: ASSERT (0); break; # 728| } Error: GCC_ANALYZER_WARNING (CWE-404): [#def71] gmp-6.3.0/scanf/doscan.c:764:3: warning[-Wanalyzer-va-list-leak]: missing call to 'va_end' gmp-6.3.0/scanf/doscan.c:489:3: acquire_resource: 'va_copy' called here gmp-6.3.0/scanf/doscan.c:764:3: throw: if the called function throws an exception... gmp-6.3.0/scanf/doscan.c:764:3: danger: missing call to 'va_end' to match 'va_copy' at [(1)](sarif:/runs/0/results/11/codeFlows/0/threadFlows/0/locations/0) # 762| # 763| done: # 764|-> (*__gmp_free_func) (alloc_fmt, alloc_fmt_size); # 765| return fields; # 766| } Error: GCC_ANALYZER_WARNING (CWE-404): [#def72] gmp-6.3.0/scanf/doscan.c:765:10: warning[-Wanalyzer-va-list-leak]: missing call to 'va_end' gmp-6.3.0/scanf/doscan.c:489:3: acquire_resource: 'va_copy' called here gmp-6.3.0/scanf/doscan.c:765:10: danger: missing call to 'va_end' to match 'va_copy' at [(1)](sarif:/runs/0/results/12/codeFlows/0/threadFlows/0/locations/0) # 763| done: # 764| (*__gmp_free_func) (alloc_fmt, alloc_fmt_size); # 765|-> return fields; # 766| } Error: GCC_ANALYZER_WARNING (CWE-404): [#def73] gmp-6.3.0/scanf/fscanf.c:44:9: warning[-Wanalyzer-va-list-leak]: missing call to 'va_end' gmp-6.3.0/scanf/fscanf.c:42:3: acquire_resource: 'va_start' called here gmp-6.3.0/scanf/fscanf.c:44:9: throw: if '__gmp_doscan' throws an exception... gmp-6.3.0/scanf/fscanf.c:44:9: danger: missing call to 'va_end' to match 'va_start' at [(1)](sarif:/runs/0/results/0/codeFlows/0/threadFlows/0/locations/0) # 42| va_start (ap, fmt); # 43| # 44|-> ret = __gmp_doscan (&__gmp_fscanf_funs, fp, fmt, ap); # 45| va_end (ap); # 46| return ret; Error: GCC_ANALYZER_WARNING (CWE-404): [#def74] gmp-6.3.0/scanf/scanf.c:44:9: warning[-Wanalyzer-va-list-leak]: missing call to 'va_end' gmp-6.3.0/scanf/scanf.c:42:3: acquire_resource: 'va_start' called here gmp-6.3.0/scanf/scanf.c:44:9: throw: if '__gmp_doscan' throws an exception... gmp-6.3.0/scanf/scanf.c:44:9: danger: missing call to 'va_end' to match 'va_start' at [(1)](sarif:/runs/0/results/0/codeFlows/0/threadFlows/0/locations/0) # 42| va_start (ap, fmt); # 43| # 44|-> ret = __gmp_doscan (&__gmp_fscanf_funs, stdin, fmt, ap); # 45| va_end (ap); # 46| return ret; Error: GCC_ANALYZER_WARNING (CWE-404): [#def75] gmp-6.3.0/scanf/sscanf.c:48:9: warning[-Wanalyzer-va-list-leak]: missing call to 'va_end' gmp-6.3.0/scanf/sscanf.c:42:3: acquire_resource: 'va_start' called here gmp-6.3.0/scanf/sscanf.c:48:9: throw: if '__gmp_doscan' throws an exception... gmp-6.3.0/scanf/sscanf.c:48:9: danger: missing call to 'va_end' to match 'va_start' at [(1)](sarif:/runs/0/results/0/codeFlows/0/threadFlows/0/locations/0) # 46| ret = gmp_vsscanf (s, fmt, ap); # 47| #else # 48|-> ret = __gmp_doscan (&__gmp_sscanf_funs, (void *) &s, fmt, ap); # 49| #endif # 50| va_end (ap);
| analyzer-version-clippy | 1.92.0 |
| analyzer-version-cppcheck | 2.19.1 |
| analyzer-version-gcc | 16.0.0 |
| analyzer-version-gcc-analyzer | 16.0.0 |
| 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-13.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.20250521.132812.g8eff701.main-1.el9.noarch |
| mock-config | fedora-rawhide-x86_64 |
| project-name | gmp-6.3.0-4.fc44 |
| store-results-to | /tmp/tmpxy_5k4eu/gmp-6.3.0-4.fc44.tar.xz |
| time-created | 2026-01-08 16:28:37 |
| time-finished | 2026-01-08 16:34:03 |
| tool | csmock |
| tool-args | '/usr/bin/csmock' '-r' 'fedora-rawhide-x86_64' '-t' 'gcc,cppcheck,clippy,shellcheck,unicontrol' '-o' '/tmp/tmpxy_5k4eu/gmp-6.3.0-4.fc44.tar.xz' '--gcc-analyze' '--unicontrol-notests' '--unicontrol-bidi-only' '--install' 'pam' '--gcc-analyzer-bin=/usr/bin/gcc' '/tmp/tmpxy_5k4eu/gmp-6.3.0-4.fc44.src.rpm' |
| tool-version | csmock-3.8.3.20251215.161544.g62de9a5-1.el9 |