2025-09-01 04:20 ftp://ftp.de.debian.org/debian/pool/main/libd/libdogleg/libdogleg_0.16.orig.tar.gz cppcheck-options: --library=posix --library=gnu --library=bsd --inconclusive --enable=style,information --inline-suppr --template=daca2 --disable=missingInclude --suppress=unmatchedSuppression --check-library --debug-warnings --suppress=autoNoType --suppress=valueFlowBailout --suppress=bailoutUninitVar --suppress=symbolDatabaseWarning --suppress=normalCheckLevelConditionExpressions -D__GNUC__ --platform=unix64 -j4 platform: Linux-6.12.41+deb13-amd64-x86_64-with-glibc2.41 python: 3.13.5 client-version: 1.3.67 compiler: g++ (Debian 14.2.0-19) 14.2.0 cppcheck: head 2.18.0 head-info: 2ee39fe (2025-08-30 22:07:31 +0200) count: 9 66 elapsed-time: 0.1 0.3 head-timing-info: old-timing-info: head results: libdogleg-0.16/dogleg.c:14:0: error: failed to evaluate #if condition, undefined function-like macro invocation: CHOLMOD_VER_CODE( ... ) [preprocessorErrorDirective] libdogleg-0.16/dogleg.c:14:2: error: failed to evaluate #if condition, undefined function-like macro invocation: CHOLMOD_VER_CODE( ... ) [preprocessorErrorDirective] libdogleg-0.16/sample.c:58:35: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable RAND_MAX [valueFlowBailoutIncompleteVar] libdogleg-0.16/sample.c:188:17: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable stderr [valueFlowBailoutIncompleteVar] libdogleg-0.16/sample.c:173:26: style: Parameter 'argv' can be declared as const array [constParameter] libdogleg-0.16/sample.c:101:18: style: Variable 'norm2_x' is assigned a value that is never used. [unreadVariable] libdogleg-0.16/sample.c:114:13: style: Variable 'norm2_x' is assigned a value that is never used. [unreadVariable] libdogleg-0.16/sample.c:142:18: style: Variable 'norm2_x' is assigned a value that is never used. [unreadVariable] libdogleg-0.16/sample.c:155:13: style: Variable 'norm2_x' is assigned a value that is never used. [unreadVariable] diff: 2.18.0 libdogleg-0.16/dogleg.c:1029:3: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable stderr [valueFlowBailoutIncompleteVar] 2.18.0 libdogleg-0.16/dogleg.c:110:10: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable stdout [valueFlowBailoutIncompleteVar] 2.18.0 libdogleg-0.16/dogleg.c:1111:3: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable stderr [valueFlowBailoutIncompleteVar] 2.18.0 libdogleg-0.16/dogleg.c:1170:3: warning: If memory allocation fails, then there is a possible null pointer dereference: ctx [nullPointerOutOfMemory] libdogleg-0.16/dogleg.c:1169:39: note: Assuming allocation function fails libdogleg-0.16/dogleg.c:1169:39: note: Assignment 'ctx=malloc(sizeof(struct dogleg_solverContext_t))', assigned value is 0 libdogleg-0.16/dogleg.c:1170:3: note: Null pointer dereference 2.18.0 libdogleg-0.16/dogleg.c:1171:3: warning: If memory allocation fails, then there is a possible null pointer dereference: ctx [nullPointerOutOfMemory] libdogleg-0.16/dogleg.c:1169:39: note: Assuming allocation function fails libdogleg-0.16/dogleg.c:1169:39: note: Assignment 'ctx=malloc(sizeof(struct dogleg_solverContext_t))', assigned value is 0 libdogleg-0.16/dogleg.c:1171:3: note: Null pointer dereference 2.18.0 libdogleg-0.16/dogleg.c:1172:3: warning: If memory allocation fails, then there is a possible null pointer dereference: ctx [nullPointerOutOfMemory] libdogleg-0.16/dogleg.c:1169:39: note: Assuming allocation function fails libdogleg-0.16/dogleg.c:1169:39: note: Assignment 'ctx=malloc(sizeof(struct dogleg_solverContext_t))', assigned value is 0 libdogleg-0.16/dogleg.c:1172:3: note: Null pointer dereference 2.18.0 libdogleg-0.16/dogleg.c:1173:3: warning: If memory allocation fails, then there is a possible null pointer dereference: ctx [nullPointerOutOfMemory] libdogleg-0.16/dogleg.c:1169:39: note: Assuming allocation function fails libdogleg-0.16/dogleg.c:1169:39: note: Assignment 'ctx=malloc(sizeof(struct dogleg_solverContext_t))', assigned value is 0 libdogleg-0.16/dogleg.c:1173:3: note: Null pointer dereference 2.18.0 libdogleg-0.16/dogleg.c:1174:3: warning: If memory allocation fails, then there is a possible null pointer dereference: ctx [nullPointerOutOfMemory] libdogleg-0.16/dogleg.c:1169:39: note: Assuming allocation function fails libdogleg-0.16/dogleg.c:1169:39: note: Assignment 'ctx=malloc(sizeof(struct dogleg_solverContext_t))', assigned value is 0 libdogleg-0.16/dogleg.c:1174:3: note: Null pointer dereference 2.18.0 libdogleg-0.16/dogleg.c:1175:3: warning: If memory allocation fails, then there is a possible null pointer dereference: ctx [nullPointerOutOfMemory] libdogleg-0.16/dogleg.c:1169:39: note: Assuming allocation function fails libdogleg-0.16/dogleg.c:1169:39: note: Assignment 'ctx=malloc(sizeof(struct dogleg_solverContext_t))', assigned value is 0 libdogleg-0.16/dogleg.c:1175:3: note: Null pointer dereference 2.18.0 libdogleg-0.16/dogleg.c:1176:3: warning: If memory allocation fails, then there is a possible null pointer dereference: ctx [nullPointerOutOfMemory] libdogleg-0.16/dogleg.c:1169:39: note: Assuming allocation function fails libdogleg-0.16/dogleg.c:1169:39: note: Assignment 'ctx=malloc(sizeof(struct dogleg_solverContext_t))', assigned value is 0 libdogleg-0.16/dogleg.c:1176:3: note: Null pointer dereference 2.18.0 libdogleg-0.16/dogleg.c:1178:7: warning: If memory allocation fails, then there is a possible null pointer dereference: ctx [nullPointerOutOfMemory] libdogleg-0.16/dogleg.c:1169:39: note: Assuming allocation function fails libdogleg-0.16/dogleg.c:1169:39: note: Assignment 'ctx=malloc(sizeof(struct dogleg_solverContext_t))', assigned value is 0 libdogleg-0.16/dogleg.c:1178:7: note: Null pointer dereference 2.18.0 libdogleg-0.16/dogleg.c:1188:7: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable stderr [valueFlowBailoutIncompleteVar] 2.18.0 libdogleg-0.16/dogleg.c:1195:5: warning: If memory allocation fails, then there is a possible null pointer dereference: ctx [nullPointerOutOfMemory] libdogleg-0.16/dogleg.c:1169:39: note: Assuming allocation function fails libdogleg-0.16/dogleg.c:1169:39: note: Assignment 'ctx=malloc(sizeof(struct dogleg_solverContext_t))', assigned value is 0 libdogleg-0.16/dogleg.c:1195:5: note: Null pointer dereference 2.18.0 libdogleg-0.16/dogleg.c:1197:3: warning: If memory allocation fails, then there is a possible null pointer dereference: ctx [nullPointerOutOfMemory] libdogleg-0.16/dogleg.c:1169:39: note: Assuming allocation function fails libdogleg-0.16/dogleg.c:1169:39: note: Assignment 'ctx=malloc(sizeof(struct dogleg_solverContext_t))', assigned value is 0 libdogleg-0.16/dogleg.c:1197:3: note: Null pointer dereference 2.18.0 libdogleg-0.16/dogleg.c:1198:3: warning: If memory allocation fails, then there is a possible null pointer dereference: ctx [nullPointerOutOfMemory] libdogleg-0.16/dogleg.c:1169:39: note: Assuming allocation function fails libdogleg-0.16/dogleg.c:1169:39: note: Assignment 'ctx=malloc(sizeof(struct dogleg_solverContext_t))', assigned value is 0 libdogleg-0.16/dogleg.c:1198:3: note: Null pointer dereference 2.18.0 libdogleg-0.16/dogleg.c:1200:10: warning: If memory allocation fails, then there is a possible null pointer dereference: ctx [nullPointerOutOfMemory] libdogleg-0.16/dogleg.c:1169:39: note: Assuming allocation function fails libdogleg-0.16/dogleg.c:1169:39: note: Assignment 'ctx=malloc(sizeof(struct dogleg_solverContext_t))', assigned value is 0 libdogleg-0.16/dogleg.c:1200:10: note: Null pointer dereference 2.18.0 libdogleg-0.16/dogleg.c:1204:21: warning: If memory allocation fails, then there is a possible null pointer dereference: ctx [nullPointerOutOfMemory] libdogleg-0.16/dogleg.c:1169:39: note: Assuming allocation function fails libdogleg-0.16/dogleg.c:1169:39: note: Assignment 'ctx=malloc(sizeof(struct dogleg_solverContext_t))', assigned value is 0 libdogleg-0.16/dogleg.c:1204:21: note: Null pointer dereference 2.18.0 libdogleg-0.16/dogleg.c:1208:13: warning: If memory allocation fails, then there is a possible null pointer dereference: ctx [nullPointerOutOfMemory] libdogleg-0.16/dogleg.c:1169:39: note: Assuming allocation function fails libdogleg-0.16/dogleg.c:1169:39: note: Assignment 'ctx=malloc(sizeof(struct dogleg_solverContext_t))', assigned value is 0 libdogleg-0.16/dogleg.c:1208:13: note: Null pointer dereference 2.18.0 libdogleg-0.16/dogleg.c:1210:3: warning: If memory allocation fails, then there is a possible null pointer dereference: ctx [nullPointerOutOfMemory] libdogleg-0.16/dogleg.c:1169:39: note: Assuming allocation function fails libdogleg-0.16/dogleg.c:1169:39: note: Assignment 'ctx=malloc(sizeof(struct dogleg_solverContext_t))', assigned value is 0 libdogleg-0.16/dogleg.c:1210:3: note: Null pointer dereference 2.18.0 libdogleg-0.16/dogleg.c:1227:5: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable stderr [valueFlowBailoutIncompleteVar] 2.18.0 libdogleg-0.16/dogleg.c:1227:5: warning: %d in format string (no. 3) requires 'int' but the argument type is 'unsigned int'. [invalidPrintfArgType_sint] 2.18.0 libdogleg-0.16/dogleg.c:1353:19: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable CHOLMOD_A [valueFlowBailoutIncompleteVar] head libdogleg-0.16/dogleg.c:14:0: error: failed to evaluate #if condition, undefined function-like macro invocation: CHOLMOD_VER_CODE( ... ) [preprocessorErrorDirective] head libdogleg-0.16/dogleg.c:14:2: error: failed to evaluate #if condition, undefined function-like macro invocation: CHOLMOD_VER_CODE( ... ) [preprocessorErrorDirective] 2.18.0 libdogleg-0.16/dogleg.c:1758:17: style: Variable 'featureSize' is assigned a value that is never used. [unreadVariable] 2.18.0 libdogleg-0.16/dogleg.c:1763:17: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable DBL_MAX [valueFlowBailoutIncompleteVar] 2.18.0 libdogleg-0.16/dogleg.c:1852:65: style: Parameter 'ctx' can be declared as pointer to const [constParameterPointer] 2.18.0 libdogleg-0.16/dogleg.c:1864:5: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable stderr [valueFlowBailoutIncompleteVar] 2.18.0 libdogleg-0.16/dogleg.c:1921:30: warning: Uninitialized variable: A [uninitvar] libdogleg-0.16/dogleg.c:1909:19: note: Assuming condition is false libdogleg-0.16/dogleg.c:1921:30: note: Uninitialized variable: A 2.18.0 libdogleg-0.16/dogleg.c:1956:5: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable stderr [valueFlowBailoutIncompleteVar] 2.18.0 libdogleg-0.16/dogleg.c:2027:30: warning: Uninitialized variable: A [uninitvar] libdogleg-0.16/dogleg.c:2010:19: note: Assuming condition is false libdogleg-0.16/dogleg.c:2027:30: note: Uninitialized variable: A 2.18.0 libdogleg-0.16/dogleg.c:2230:47: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable CHOLMOD_INT [valueFlowBailoutIncompleteVar] 2.18.0 libdogleg-0.16/dogleg.c:2281:10: style: Variable 'traceBB' is assigned a value that is never used. [unreadVariable] 2.18.0 libdogleg-0.16/dogleg.c:2281:18: style: Variable 'traceBB' is assigned a value that is never used. [unreadVariable] 2.18.0 libdogleg-0.16/dogleg.c:2392:34: debug: Function::addArguments found argument 'getConfidence' with varid 0. [varid0] 2.18.0 libdogleg-0.16/dogleg.c:2410:9: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable stderr [valueFlowBailoutIncompleteVar] 2.18.0 libdogleg-0.16/dogleg.c:2474:37: debug: Function::addArguments found argument 'getConfidence' with varid 0. [varid0] 2.18.0 libdogleg-0.16/dogleg.c:2492:9: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable stderr [valueFlowBailoutIncompleteVar] 2.18.0 libdogleg-0.16/dogleg.c:329:3: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable stderr [valueFlowBailoutIncompleteVar] 2.18.0 libdogleg-0.16/dogleg.c:400:5: warning: %d in format string (no. 1) requires 'int' but the argument type is 'unsigned int'. [invalidPrintfArgType_sint] 2.18.0 libdogleg-0.16/dogleg.c:400:5: warning: %d in format string (no. 2) requires 'int' but the argument type is 'unsigned int'. [invalidPrintfArgType_sint] 2.18.0 libdogleg-0.16/dogleg.c:428:5: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable stderr [valueFlowBailoutIncompleteVar] 2.18.0 libdogleg-0.16/dogleg.c:428:5: warning: %d in format string (no. 3) requires 'int' but the argument type is 'unsigned int'. [invalidPrintfArgType_sint] 2.18.0 libdogleg-0.16/dogleg.c:477:5: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable stderr [valueFlowBailoutIncompleteVar] 2.18.0 libdogleg-0.16/dogleg.c:506:7: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable stderr [valueFlowBailoutIncompleteVar] 2.18.0 libdogleg-0.16/dogleg.c:615:44: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable CHOLMOD_REAL [valueFlowBailoutIncompleteVar] 2.18.0 libdogleg-0.16/dogleg.c:691:5: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable stderr [valueFlowBailoutIncompleteVar] 2.18.0 libdogleg-0.16/dogleg.c:718:7: warning: If memory allocation fails, then there is a possible null pointer dereference: ctx [nullPointerOutOfMemory] libdogleg-0.16/dogleg.c:1169:39: note: Assuming allocation function fails libdogleg-0.16/dogleg.c:1169:39: note: Assignment 'ctx=malloc(sizeof(struct dogleg_solverContext_t))', assigned value is 0 libdogleg-0.16/dogleg.c:1203:34: note: Calling function 'runOptimizer', 1st argument 'ctx' value is 0 libdogleg-0.16/dogleg.c:936:54: note: Calling function 'computeCallbackOperatingPoint', 2nd argument 'ctx' value is 0 libdogleg-0.16/dogleg.c:718:7: note: Null pointer dereference 2.18.0 libdogleg-0.16/dogleg.c:72:3: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable INFINITY [valueFlowBailoutIncompleteVar] 2.18.0 libdogleg-0.16/dogleg.c:741:36: warning: If memory allocation fails, then there is a possible null pointer dereference: ctx [nullPointerOutOfMemory] libdogleg-0.16/dogleg.c:1169:39: note: Assuming allocation function fails libdogleg-0.16/dogleg.c:1169:39: note: Assignment 'ctx=malloc(sizeof(struct dogleg_solverContext_t))', assigned value is 0 libdogleg-0.16/dogleg.c:1203:34: note: Calling function 'runOptimizer', 1st argument 'ctx' value is 0 libdogleg-0.16/dogleg.c:936:54: note: Calling function 'computeCallbackOperatingPoint', 2nd argument 'ctx' value is 0 libdogleg-0.16/dogleg.c:741:36: note: Null pointer dereference 2.18.0 libdogleg-0.16/dogleg.c:745:18: warning: If memory allocation fails, then there is a possible null pointer dereference: ctx [nullPointerOutOfMemory] libdogleg-0.16/dogleg.c:1169:39: note: Assuming allocation function fails libdogleg-0.16/dogleg.c:1169:39: note: Assignment 'ctx=malloc(sizeof(struct dogleg_solverContext_t))', assigned value is 0 libdogleg-0.16/dogleg.c:1203:34: note: Calling function 'runOptimizer', 1st argument 'ctx' value is 0 libdogleg-0.16/dogleg.c:936:54: note: Calling function 'computeCallbackOperatingPoint', 2nd argument 'ctx' value is 0 libdogleg-0.16/dogleg.c:745:18: note: Null pointer dereference 2.18.0 libdogleg-0.16/dogleg.c:746:31: warning: If memory allocation fails, then there is a possible null pointer dereference: ctx [nullPointerOutOfMemory] libdogleg-0.16/dogleg.c:1169:39: note: Assuming allocation function fails libdogleg-0.16/dogleg.c:1169:39: note: Assignment 'ctx=malloc(sizeof(struct dogleg_solverContext_t))', assigned value is 0 libdogleg-0.16/dogleg.c:1203:34: note: Calling function 'runOptimizer', 1st argument 'ctx' value is 0 libdogleg-0.16/dogleg.c:936:54: note: Calling function 'computeCallbackOperatingPoint', 2nd argument 'ctx' value is 0 libdogleg-0.16/dogleg.c:746:31: note: Null pointer dereference 2.18.0 libdogleg-0.16/dogleg.c:748:3: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable stderr [valueFlowBailoutIncompleteVar] 2.18.0 libdogleg-0.16/dogleg.c:748:3: warning: If memory allocation fails, then there is a possible null pointer dereference: ctx [nullPointerOutOfMemory] libdogleg-0.16/dogleg.c:1169:39: note: Assuming allocation function fails libdogleg-0.16/dogleg.c:1169:39: note: Assignment 'ctx=malloc(sizeof(struct dogleg_solverContext_t))', assigned value is 0 libdogleg-0.16/dogleg.c:1203:34: note: Calling function 'runOptimizer', 1st argument 'ctx' value is 0 libdogleg-0.16/dogleg.c:936:54: note: Calling function 'computeCallbackOperatingPoint', 2nd argument 'ctx' value is 0 libdogleg-0.16/dogleg.c:746:29: note: Assuming condition is false libdogleg-0.16/dogleg.c:748:3: note: Null pointer dereference 2.18.0 libdogleg-0.16/dogleg.c:779:3: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable stderr [valueFlowBailoutIncompleteVar] 2.18.0 libdogleg-0.16/dogleg.c:84:11: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable INFINITY [valueFlowBailoutIncompleteVar] 2.18.0 libdogleg-0.16/dogleg.c:896:3: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable stderr [valueFlowBailoutIncompleteVar] 2.18.0 libdogleg-0.16/dogleg.c:933:24: warning: If memory allocation fails, then there is a possible null pointer dereference: ctx [nullPointerOutOfMemory] libdogleg-0.16/dogleg.c:1169:39: note: Assuming allocation function fails libdogleg-0.16/dogleg.c:1169:39: note: Assignment 'ctx=malloc(sizeof(struct dogleg_solverContext_t))', assigned value is 0 libdogleg-0.16/dogleg.c:1203:34: note: Calling function 'runOptimizer', 1st argument 'ctx' value is 0 libdogleg-0.16/dogleg.c:933:24: note: Null pointer dereference 2.18.0 libdogleg-0.16/dogleg.c:936:37: warning: If memory allocation fails, then there is a possible null pointer dereference: ctx [nullPointerOutOfMemory] libdogleg-0.16/dogleg.c:1169:39: note: Assuming allocation function fails libdogleg-0.16/dogleg.c:1169:39: note: Assignment 'ctx=malloc(sizeof(struct dogleg_solverContext_t))', assigned value is 0 libdogleg-0.16/dogleg.c:1203:34: note: Calling function 'runOptimizer', 1st argument 'ctx' value is 0 libdogleg-0.16/dogleg.c:936:37: note: Null pointer dereference 2.18.0 libdogleg-0.16/dogleg.c:939:3: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable stderr [valueFlowBailoutIncompleteVar] 2.18.0 libdogleg-0.16/dogleg.c:939:3: warning: If memory allocation fails, then there is a possible null pointer dereference: ctx [nullPointerOutOfMemory] libdogleg-0.16/dogleg.c:1169:39: note: Assuming allocation function fails libdogleg-0.16/dogleg.c:1169:39: note: Assignment 'ctx=malloc(sizeof(struct dogleg_solverContext_t))', assigned value is 0 libdogleg-0.16/dogleg.c:1203:34: note: Calling function 'runOptimizer', 1st argument 'ctx' value is 0 libdogleg-0.16/dogleg.c:936:36: note: Assuming condition is false libdogleg-0.16/dogleg.c:939:3: note: Null pointer dereference DONE