2024-04-21 09:59 ftp://ftp.de.debian.org/debian/pool/main/p/python-getdns/python-getdns_1.0.0~b1.orig.tar.gz cppcheck-options: --library=posix --library=gnu --library=python --showtime=top5 --check-library --inconclusive --enable=style,information --inline-suppr --disable=missingInclude --suppress=unmatchedSuppression --template=daca2 --debug-warnings --suppress=autoNoType --suppress=valueFlowBailout --suppress=bailoutUninitVar --suppress=symbolDatabaseWarning -D__GNUC__ --platform=unix64 -j1 platform: Linux-6.6.15-amd64-x86_64-with-glibc2.37 python: 3.11.8 client-version: 1.3.49 compiler: g++ (Debian 13.2.0-13) 13.2.0 cppcheck: head 2.14.0 head-info: 4f922b0 (2024-04-21 11:41:48 +0200) count: 106 106 elapsed-time: 0.7 0.8 head-timing-info: Tokenizer::simplifyTokens1::ValueFlow: 0.473011s (avg. 0.0946022s - 5 result(s)) valueFlowUninit(tokenlist, errorLogger, settings): 0.175003s (avg. 0.0145836s - 12 result(s)) valueFlowAfterAssign(tokenlist, symboldatabase, errorLogger, settings, skippedFunctions): 0.133757s (avg. 0.0111464s - 12 result(s)) valueFlowCondition(SimpleConditionHandler{}, tokenlist, symboldatabase, errorLogger, settings, skippedFunctions): 0.08652s (avg. 0.00721s - 12 result(s)) Tokenizer::simplifyTokens1::createSymbolDatabase: 0.042634s (avg. 0.0085268s - 5 result(s)) Overall time: 0.621971s old-timing-info: Tokenizer::simplifyTokens1::ValueFlow: 0.473631s (avg. 0.0947262s - 5 result(s)) valueFlowUninit(tokenlist, errorLogger, settings): 0.174568s (avg. 0.0145473s - 12 result(s)) valueFlowAfterAssign(tokenlist, symboldatabase, errorLogger, settings, skippedFunctions): 0.132649s (avg. 0.0110541s - 12 result(s)) valueFlowCondition(SimpleConditionHandler{}, tokenlist, symboldatabase, errorLogger, settings, skippedFunctions): 0.089056s (avg. 0.00742133s - 12 result(s)) Tokenizer::simplifyTokens1::createSymbolDatabase: 0.043329s (avg. 0.0086658s - 5 result(s)) Overall time: 0.625095s head results: getdns-python-bindings-1.0.0b1/context.c:49:39: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable GETDNS_RETURN_INVALID_PARAMETER_TEXT [valueFlowBailoutIncompleteVar] getdns-python-bindings-1.0.0b1/context.c:94:39: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable GETDNS_RETURN_INVALID_PARAMETER_TEXT [valueFlowBailoutIncompleteVar] getdns-python-bindings-1.0.0b1/context.c:124:39: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable GETDNS_RETURN_INVALID_PARAMETER_TEXT [valueFlowBailoutIncompleteVar] getdns-python-bindings-1.0.0b1/context.c:154:39: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable GETDNS_RETURN_INVALID_PARAMETER_TEXT [valueFlowBailoutIncompleteVar] getdns-python-bindings-1.0.0b1/context.c:188:39: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable GETDNS_RETURN_INVALID_PARAMETER_TEXT [valueFlowBailoutIncompleteVar] getdns-python-bindings-1.0.0b1/context.c:219:39: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable GETDNS_RETURN_INVALID_PARAMETER_TEXT [valueFlowBailoutIncompleteVar] getdns-python-bindings-1.0.0b1/context.c:254:39: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable GETDNS_RETURN_INVALID_PARAMETER_TEXT [valueFlowBailoutIncompleteVar] getdns-python-bindings-1.0.0b1/context.c:291:39: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable GETDNS_RETURN_INVALID_PARAMETER_TEXT [valueFlowBailoutIncompleteVar] getdns-python-bindings-1.0.0b1/context.c:340:39: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable GETDNS_RETURN_INVALID_PARAMETER_TEXT [valueFlowBailoutIncompleteVar] getdns-python-bindings-1.0.0b1/context.c:370:39: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable GETDNS_RETURN_INVALID_PARAMETER_TEXT [valueFlowBailoutIncompleteVar] getdns-python-bindings-1.0.0b1/context.c:401:39: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable GETDNS_RETURN_INVALID_PARAMETER_TEXT [valueFlowBailoutIncompleteVar] getdns-python-bindings-1.0.0b1/context.c:432:39: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable GETDNS_RETURN_INVALID_PARAMETER_TEXT [valueFlowBailoutIncompleteVar] getdns-python-bindings-1.0.0b1/context.c:531:39: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable GETDNS_RETURN_INVALID_PARAMETER_TEXT [valueFlowBailoutIncompleteVar] getdns-python-bindings-1.0.0b1/context.c:562:39: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable GETDNS_RETURN_INVALID_PARAMETER_TEXT [valueFlowBailoutIncompleteVar] getdns-python-bindings-1.0.0b1/context.c:595:39: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable GETDNS_RETURN_INVALID_PARAMETER_TEXT [valueFlowBailoutIncompleteVar] getdns-python-bindings-1.0.0b1/context.c:636:37: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable in6_addr [valueFlowBailoutIncompleteVar] getdns-python-bindings-1.0.0b1/context.c:730:39: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable GETDNS_RETURN_INVALID_PARAMETER_TEXT [valueFlowBailoutIncompleteVar] getdns-python-bindings-1.0.0b1/context.c:777:39: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable GETDNS_RETURN_INVALID_PARAMETER_TEXT [valueFlowBailoutIncompleteVar] getdns-python-bindings-1.0.0b1/context.c:821:39: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable GETDNS_RETURN_INVALID_PARAMETER_TEXT [valueFlowBailoutIncompleteVar] getdns-python-bindings-1.0.0b1/context.c:874:72: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable GETDNS_RETURN_GOOD [valueFlowBailoutIncompleteVar] getdns-python-bindings-1.0.0b1/context.c:1204:39: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable GETDNS_RETURN_INVALID_PARAMETER_TEXT [valueFlowBailoutIncompleteVar] getdns-python-bindings-1.0.0b1/context.c:1245:39: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable GETDNS_RETURN_BAD_CONTEXT_TEXT [valueFlowBailoutIncompleteVar] getdns-python-bindings-1.0.0b1/context.c:1265:39: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable GETDNS_RETURN_BAD_CONTEXT_TEXT [valueFlowBailoutIncompleteVar] getdns-python-bindings-1.0.0b1/context.c:1291:39: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable GETDNS_RETURN_GENERIC_ERROR_TEXT [valueFlowBailoutIncompleteVar] getdns-python-bindings-1.0.0b1/context.c:1327:39: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable GETDNS_RETURN_BAD_CONTEXT_TEXT [valueFlowBailoutIncompleteVar] getdns-python-bindings-1.0.0b1/context.c:1416:39: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable GETDNS_RETURN_BAD_CONTEXT_TEXT [valueFlowBailoutIncompleteVar] getdns-python-bindings-1.0.0b1/context.c:1507:39: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable GETDNS_RETURN_BAD_CONTEXT_TEXT [valueFlowBailoutIncompleteVar] getdns-python-bindings-1.0.0b1/context.c:1603:39: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable GETDNS_RETURN_BAD_CONTEXT_TEXT [valueFlowBailoutIncompleteVar] getdns-python-bindings-1.0.0b1/context.c:1685:39: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable GETDNS_RETURN_BAD_CONTEXT_TEXT [valueFlowBailoutIncompleteVar] getdns-python-bindings-1.0.0b1/context.c:407:53: style: Comparing expression of type 'unsigned char' against value 0. Condition is always false. [compareValueOutOfTypeRangeError] getdns-python-bindings-1.0.0b1/context.c:537:53: style: Comparing expression of type 'unsigned char' against value 0. Condition is always false. [compareValueOutOfTypeRangeError] getdns-python-bindings-1.0.0b1/context.c:568:53: style: Comparing expression of type 'unsigned char' against value 0. Condition is always false. [compareValueOutOfTypeRangeError] getdns-python-bindings-1.0.0b1/context.c:346:58: style: Condition '(long)(value=(uint32_t)PyInt_AsLong(py_value))<0' is always false [knownConditionTrueFalse] getdns-python-bindings-1.0.0b1/context.c:376:48: style: Condition '(long)(value=PyInt_AsLong(py_value))<0' is always false [knownConditionTrueFalse] getdns-python-bindings-1.0.0b1/context.c:1361:17: error: Memory leak: blob [memleak] getdns-python-bindings-1.0.0b1/context.c:1368:13: error: Memory leak: blob [memleak] getdns-python-bindings-1.0.0b1/context.c:1453:17: error: Memory leak: blob [memleak] getdns-python-bindings-1.0.0b1/context.c:1460:13: error: Memory leak: blob [memleak] getdns-python-bindings-1.0.0b1/context.c:1550:17: error: Memory leak: blob [memleak] getdns-python-bindings-1.0.0b1/context.c:1557:13: error: Memory leak: blob [memleak] getdns-python-bindings-1.0.0b1/context.c:1640:17: error: Memory leak: blob [memleak] getdns-python-bindings-1.0.0b1/context.c:1647:13: error: Memory leak: blob [memleak] getdns-python-bindings-1.0.0b1/context.c:674:17: error: Memory leak: addr_type.data [memleak] getdns-python-bindings-1.0.0b1/context.c:407:51: style: Checking if unsigned expression 'value=(uint8_t)PyInt_AsLong(py_value)' is less than zero. [unsignedLessThanZero] getdns-python-bindings-1.0.0b1/context.c:537:51: style: Checking if unsigned expression 'value=(uint8_t)PyInt_AsLong(py_value)' is less than zero. [unsignedLessThanZero] getdns-python-bindings-1.0.0b1/context.c:568:51: style: Checking if unsigned expression 'value=(uint8_t)PyInt_AsLong(py_value)' is less than zero. [unsignedLessThanZero] getdns-python-bindings-1.0.0b1/context.c:1189:64: style:inconclusive: Function 'context_setattro' argument 3 names different: declaration 'value' definition 'py_value'. [funcArgNamesDifferent] getdns-python-bindings-1.0.0b1/pygetdns.h:132:68: note: Function 'context_setattro' argument 3 names different: declaration 'value' definition 'py_value'. getdns-python-bindings-1.0.0b1/context.c:1189:64: note: Function 'context_setattro' argument 3 names different: declaration 'value' definition 'py_value'. getdns-python-bindings-1.0.0b1/context.c:1104:25: style: Local variable 'ret' shadows outer variable [shadowVariable] getdns-python-bindings-1.0.0b1/context.c:862:21: note: Shadowed declaration getdns-python-bindings-1.0.0b1/context.c:1104:25: note: Shadow variable getdns-python-bindings-1.0.0b1/context.c:1125:25: style: Local variable 'ret' shadows outer variable [shadowVariable] getdns-python-bindings-1.0.0b1/context.c:862:21: note: Shadowed declaration getdns-python-bindings-1.0.0b1/context.c:1125:25: note: Shadow variable getdns-python-bindings-1.0.0b1/context.c:863:11: style: Variable 'attrname' can be declared as pointer to const [constVariablePointer] getdns-python-bindings-1.0.0b1/context.c:1181:26: style: Variable 's1' can be declared as pointer to const [constVariablePointer] getdns-python-bindings-1.0.0b1/context.c:1182:26: style: Variable 's2' can be declared as pointer to const [constVariablePointer] getdns-python-bindings-1.0.0b1/context.c:1286:11: style: Variable 'str_api_dict' can be declared as pointer to const [constVariablePointer] getdns-python-bindings-1.0.0b1/context.c:1207:27: error: Uninitialized variable: &key.setter [uninitvar] getdns-python-bindings-1.0.0b1/context.c:1203:73: note: Assuming condition is false getdns-python-bindings-1.0.0b1/context.c:1207:27: note: Uninitialized variable: &key.setter getdns-python-bindings-1.0.0b1/context_util.c:88:17: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable GETDNS_CALLBACK_CANCEL [valueFlowBailoutIncompleteVar] getdns-python-bindings-1.0.0b1/context_util.c:73:15: style: Local variable 'py_result' shadows outer function [shadowFunction] getdns-python-bindings-1.0.0b1/pygetdns.h:114:11: note: Shadowed declaration getdns-python-bindings-1.0.0b1/context_util.c:73:15: note: Shadow variable getdns-python-bindings-1.0.0b1/getdns.c:289:39: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable GETDNS_RETURN_INVALID_PARAMETER_TEXT [valueFlowBailoutIncompleteVar] getdns-python-bindings-1.0.0b1/getdns.c:308:39: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable GETDNS_RETURN_INVALID_PARAMETER_TEXT [valueFlowBailoutIncompleteVar] getdns-python-bindings-1.0.0b1/getdns.c:333:39: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable GETDNS_RETURN_INVALID_PARAMETER_TEXT [valueFlowBailoutIncompleteVar] getdns-python-bindings-1.0.0b1/getdns.c:358:39: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable GETDNS_RETURN_INVALID_PARAMETER_TEXT [valueFlowBailoutIncompleteVar] getdns-python-bindings-1.0.0b1/getdns.c:381:5: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable PyDateTime_IMPORT [valueFlowBailoutIncompleteVar] getdns-python-bindings-1.0.0b1/getdns.c:441:33: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable PyType_GenericNew [valueFlowBailoutIncompleteVar] getdns-python-bindings-1.0.0b1/getdns.c:440:5: warning: Return value of function PyModule_AddObject() is not used. [ignoredReturnValue] getdns-python-bindings-1.0.0b1/getdns.c:446:5: warning: Return value of function PyModule_AddObject() is not used. [ignoredReturnValue] getdns-python-bindings-1.0.0b1/getdns.c:450:5: warning: Return value of function PyModule_AddObject() is not used. [ignoredReturnValue] getdns-python-bindings-1.0.0b1/getdns.c:384:11: portability: Non reentrant function 'gmtime' called. For threadsafe applications it is recommended to use the reentrant replacement function 'gmtime_r'. [prohibitedgmtimeCalled] getdns-python-bindings-1.0.0b1/getdns.c:287:11: style: Variable 'ulabel' can be declared as pointer to const [constVariablePointer] getdns-python-bindings-1.0.0b1/getdns.c:305:11: style: Variable 'alabel' can be declared as pointer to const [constVariablePointer] getdns-python-bindings-1.0.0b1/getdns.c:355:11: style: Variable 'errstr' can be declared as pointer to const [constVariablePointer] getdns-python-bindings-1.0.0b1/pygetdns_util.c:50:72: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable GETDNS_RETURN_GOOD [valueFlowBailoutIncompleteVar] getdns-python-bindings-1.0.0b1/pygetdns_util.c:62:82: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable GETDNS_RETURN_GOOD [valueFlowBailoutIncompleteVar] getdns-python-bindings-1.0.0b1/pygetdns_util.c:74:92: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable GETDNS_RETURN_GOOD [valueFlowBailoutIncompleteVar] getdns-python-bindings-1.0.0b1/pygetdns_util.c:92:9: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable GETDNS_RETURN_GOOD [valueFlowBailoutIncompleteVar] getdns-python-bindings-1.0.0b1/pygetdns_util.c:105:9: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable GETDNS_RETURN_GOOD [valueFlowBailoutIncompleteVar] getdns-python-bindings-1.0.0b1/pygetdns_util.c:118:9: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable GETDNS_RETURN_GOOD [valueFlowBailoutIncompleteVar] getdns-python-bindings-1.0.0b1/pygetdns_util.c:146:9: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable GETDNS_RETURN_GOOD [valueFlowBailoutIncompleteVar] getdns-python-bindings-1.0.0b1/pygetdns_util.c:203:47: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable GETDNS_RETURN_EXTENSION_MISFORMAT_TEXT [valueFlowBailoutIncompleteVar] getdns-python-bindings-1.0.0b1/pygetdns_util.c:372:37: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable in6_addr [valueFlowBailoutIncompleteVar] getdns-python-bindings-1.0.0b1/pygetdns_util.c:610:58: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable GETDNS_RETURN_GOOD [valueFlowBailoutIncompleteVar] getdns-python-bindings-1.0.0b1/pygetdns_util.c:684:39: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable GETDNS_RETURN_GENERIC_ERROR_TEXT [valueFlowBailoutIncompleteVar] getdns-python-bindings-1.0.0b1/pygetdns_util.c:784:55: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable GETDNS_RETURN_GOOD [valueFlowBailoutIncompleteVar] getdns-python-bindings-1.0.0b1/pygetdns_util.c:886:16: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable GETDNS_RETURN_GOOD [valueFlowBailoutIncompleteVar] getdns-python-bindings-1.0.0b1/pygetdns_util.c:936:43: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable GETDNS_RETURN_GENERIC_ERROR_TEXT [valueFlowBailoutIncompleteVar] getdns-python-bindings-1.0.0b1/pygetdns_util.c:1208:14: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable GETDNS_RETURN_GOOD [valueFlowBailoutIncompleteVar] getdns-python-bindings-1.0.0b1/pygetdns_util.c:1041:9: style: Condition 'ipdict' is always false [knownConditionTrueFalse] getdns-python-bindings-1.0.0b1/pygetdns_util.c:1040:48: note: Calling function 'getdns_dict_to_ip_string' returns 0 getdns-python-bindings-1.0.0b1/pygetdns_util.c:1040:48: note: Assignment 'ipdict=getdns_dict_to_ip_string(dict)', assigned value is 0 getdns-python-bindings-1.0.0b1/pygetdns_util.c:1041:9: note: Condition 'ipdict' is always false getdns-python-bindings-1.0.0b1/pygetdns_util.c:424:9: error: Memory leak: addr_type.data [memleak] getdns-python-bindings-1.0.0b1/pygetdns_util.c:162:11: style: Variable 'tmpoptionlistkey' can be declared as pointer to const [constVariablePointer] getdns-python-bindings-1.0.0b1/pygetdns_util.c:883:23: style: Parameter 'msg' can be declared as pointer to const [constParameterPointer] getdns-python-bindings-1.0.0b1/pygetdns_util.c:996:15: style: Variable 'ipStr' can be declared as pointer to const [constVariablePointer] getdns-python-bindings-1.0.0b1/pygetdns_util.c:1201:11: style: Variable 'addr_string' can be declared as pointer to const [constVariablePointer] getdns-python-bindings-1.0.0b1/pygetdns_util.c:50:14: style: Variable 'ret' is assigned a value that is never used. [unreadVariable] getdns-python-bindings-1.0.0b1/pygetdns_util.c:62:14: style: Variable 'ret' is assigned a value that is never used. [unreadVariable] getdns-python-bindings-1.0.0b1/pygetdns_util.c:74:14: style: Variable 'ret' is assigned a value that is never used. [unreadVariable] getdns-python-bindings-1.0.0b1/pygetdns_util.c:91:14: style: Variable 'ret' is assigned a value that is never used. [unreadVariable] getdns-python-bindings-1.0.0b1/pygetdns_util.c:104:14: style: Variable 'ret' is assigned a value that is never used. [unreadVariable] getdns-python-bindings-1.0.0b1/pygetdns_util.c:117:14: style: Variable 'ret' is assigned a value that is never used. [unreadVariable] getdns-python-bindings-1.0.0b1/pygetdns_util.c:142:14: style: Variable 'ret' is assigned a value that is never used. [unreadVariable] getdns-python-bindings-1.0.0b1/pygetdns_util.c:163:37: style: Variable 'optionslist' is assigned a value that is never used. [unreadVariable] getdns-python-bindings-1.0.0b1/pygetdns_util.c:487:18: style: Variable 'ret' is assigned a value that is never used. [unreadVariable] getdns-python-bindings-1.0.0b1/pygetdns_util.c:500:18: style: Variable 'ret' is assigned a value that is never used. [unreadVariable] getdns-python-bindings-1.0.0b1/pygetdns_util.c:513:18: style: Variable 'ret' is assigned a value that is never used. [unreadVariable] getdns-python-bindings-1.0.0b1/pygetdns_util.c:548:22: style: Variable 'ret' is assigned a value that is never used. [unreadVariable] getdns-python-bindings-1.0.0b1/result.c:58:25: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable PyExc_AttributeError [valueFlowBailoutIncompleteVar] getdns-python-bindings-1.0.0b1/result.c:119:38: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable Py_None [valueFlowBailoutIncompleteVar] getdns-python-bindings-1.0.0b1/result.c:164:5: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable Py_None [valueFlowBailoutIncompleteVar] getdns-python-bindings-1.0.0b1/result.c:50:11: style: Variable 'canonical_name' can be declared as pointer to const [constVariablePointer] diff: DONE