2025-05-05 04:18 ftp://ftp.de.debian.org/debian/pool/main/i/ipcalc-ng/ipcalc-ng_1.0.3.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 -j3 platform: Linux-6.8.0-1022-oracle-aarch64-with-glibc2.39 python: 3.12.3 client-version: 1.3.67 compiler: g++ (Ubuntu 13.3.0-6ubuntu2~24.04) 13.3.0 cppcheck: head 2.17.0 head-info: 88ef81e (2025-05-02 08:42:38 +0200) count: 53 53 elapsed-time: 0.5 0.6 head-timing-info: old-timing-info: head results: ipcalc-1.0.3/deaggregate.c:64:12: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable stderr [valueFlowBailoutIncompleteVar] ipcalc-1.0.3/deaggregate.c:88:15: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable INET_ADDRSTRLEN [valueFlowBailoutIncompleteVar] ipcalc-1.0.3/deaggregate.c:109:16: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable AF_INET [valueFlowBailoutIncompleteVar] ipcalc-1.0.3/deaggregate.c:155:15: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable INET6_ADDRSTRLEN [valueFlowBailoutIncompleteVar] ipcalc-1.0.3/deaggregate.c:184:16: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable AF_INET6 [valueFlowBailoutIncompleteVar] ipcalc-1.0.3/ipcalc-utils.c:36:11: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable stderr [valueFlowBailoutIncompleteVar] ipcalc-1.0.3/ipcalc-utils.c:47:2: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable errno [valueFlowBailoutIncompleteVar] ipcalc-1.0.3/ipcalc-utils.c:79:11: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable stderr [valueFlowBailoutIncompleteVar] ipcalc-1.0.3/ipcalc-utils.c:33:18: style: Redundant pointer operation on 'strp' - it's already a pointer. [redundantPointerOp] ipcalc-1.0.3/deaggregate.c:61:10: portability: Non reentrant function 'strtok' called. For threadsafe applications it is recommended to use the reentrant replacement function 'strtok_r'. [prohibitedstrtokCalled] ipcalc-1.0.3/deaggregate.c:71:10: portability: Non reentrant function 'strtok' called. For threadsafe applications it is recommended to use the reentrant replacement function 'strtok_r'. [prohibitedstrtokCalled] ipcalc-1.0.3/deaggregate.c:153:66: style: Parameter 'ip' can be declared as pointer to const [constParameterPointer] ipcalc-1.0.3/deaggregate.c:166:47: style: Parameter 'base' can be declared as pointer to const [constParameterPointer] ipcalc-1.0.3/ipcalc-reverse.c:37:76: style:inconclusive: Function 'calc_reverse_dns4' argument 3 names different: declaration 'net' definition 'network'. [funcArgNamesDifferent] ipcalc-1.0.3/ipcalc.h:47:76: note: Function 'calc_reverse_dns4' argument 3 names different: declaration 'net' definition 'network'. ipcalc-1.0.3/ipcalc-reverse.c:37:76: note: Function 'calc_reverse_dns4' argument 3 names different: declaration 'net' definition 'network'. ipcalc-1.0.3/ipcalc-reverse.c:37:100: style:inconclusive: Function 'calc_reverse_dns4' argument 4 names different: declaration 'bcast' definition 'broadcast'. [funcArgNamesDifferent] ipcalc-1.0.3/ipcalc.h:47:96: note: Function 'calc_reverse_dns4' argument 4 names different: declaration 'bcast' definition 'broadcast'. ipcalc-1.0.3/ipcalc-reverse.c:37:100: note: Function 'calc_reverse_dns4' argument 4 names different: declaration 'bcast' definition 'broadcast'. ipcalc-1.0.3/ipcalc-reverse.c:101:42: style: Parameter 'ip' can be declared as pointer to const [constParameterPointer] ipcalc-1.0.3/netsplit.c:44:19: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable AF_INET [valueFlowBailoutIncompleteVar] ipcalc-1.0.3/netsplit.c:60:12: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable stderr [valueFlowBailoutIncompleteVar] ipcalc-1.0.3/netsplit.c:135:19: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable AF_INET6 [valueFlowBailoutIncompleteVar] ipcalc-1.0.3/netsplit.c:146:16: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable AF_INET6 [valueFlowBailoutIncompleteVar] ipcalc-1.0.3/ipcalc.c:150:23: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable NI_MAXHOST [valueFlowBailoutIncompleteVar] ipcalc-1.0.3/ipcalc.c:199:24: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable AF_INET [valueFlowBailoutIncompleteVar] ipcalc-1.0.3/ipcalc.c:263:18: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable AF_INET [valueFlowBailoutIncompleteVar] ipcalc-1.0.3/ipcalc.c:584:15: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable INET_ADDRSTRLEN [valueFlowBailoutIncompleteVar] ipcalc-1.0.3/ipcalc.c:756:16: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable AF_INET6 [valueFlowBailoutIncompleteVar] ipcalc-1.0.3/ipcalc.c:898:16: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable AF_INET6 [valueFlowBailoutIncompleteVar] ipcalc-1.0.3/ipcalc.c:1000:28: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable O_RDONLY [valueFlowBailoutIncompleteVar] ipcalc-1.0.3/ipcalc.c:1020:20: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable CLOCK_PROCESS_CPUTIME_ID [valueFlowBailoutIncompleteVar] ipcalc-1.0.3/ipcalc.c:1134:11: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable stderr [valueFlowBailoutIncompleteVar] ipcalc-1.0.3/ipcalc.c:1259:15: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable stdout [valueFlowBailoutIncompleteVar] ipcalc-1.0.3/ipcalc.c:1294:11: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable stdout [valueFlowBailoutIncompleteVar] ipcalc-1.0.3/ipcalc.c:1325:16: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable stdout [valueFlowBailoutIncompleteVar] ipcalc-1.0.3/ipcalc.c:1349:16: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable stdout [valueFlowBailoutIncompleteVar] ipcalc-1.0.3/ipcalc.c:1458:28: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable optarg [valueFlowBailoutIncompleteVar] ipcalc-1.0.3/netsplit.c:60:4: warning: %d in format string (no. 1) requires 'int' but the argument type is 'unsigned int'. [invalidPrintfArgType_sint] ipcalc-1.0.3/netsplit.c:60:4: warning: %d in format string (no. 2) requires 'int' but the argument type is 'unsigned int'. [invalidPrintfArgType_sint] ipcalc-1.0.3/netsplit.c:166:4: warning: %d in format string (no. 1) requires 'int' but the argument type is 'unsigned int'. [invalidPrintfArgType_sint] ipcalc-1.0.3/netsplit.c:182:4: warning: %d in format string (no. 1) requires 'int' but the argument type is 'unsigned int'. [invalidPrintfArgType_sint] ipcalc-1.0.3/netsplit.c:182:4: warning: %d in format string (no. 2) requires 'int' but the argument type is 'unsigned int'. [invalidPrintfArgType_sint] ipcalc-1.0.3/netsplit.c:131:47: style: Parameter 'ip' can be declared as pointer to const [constParameterPointer] ipcalc-1.0.3/ipcalc.c:526:12: style: Condition 'byte1>=128' is always true [knownConditionTrueFalse] ipcalc-1.0.3/ipcalc.c:522:12: note: Assuming that condition 'byte1<128' is not redundant ipcalc-1.0.3/ipcalc.c:526:12: note: Condition 'byte1>=128' is always true ipcalc-1.0.3/ipcalc.c:550:12: style: Condition 'byte1>=128' is always true [knownConditionTrueFalse] ipcalc-1.0.3/ipcalc.c:546:12: note: Assuming that condition 'byte1<128' is not redundant ipcalc-1.0.3/ipcalc.c:550:12: note: Condition 'byte1>=128' is always true ipcalc-1.0.3/ipcalc.c:1649:5: warning: %u in format string (no. 1) requires 'unsigned int' but the argument type is 'signed int'. [invalidPrintfArgType_uint] ipcalc-1.0.3/ipcalc.c:148:45: style: Parameter 'addr' can be declared as pointer to const [constParameterPointer] ipcalc-1.0.3/ipcalc.c:189:8: style: Variable 'addr' can be declared as pointer to const [constVariablePointer] ipcalc-1.0.3/ipcalc.c:868:36: style: Parameter 'ip6' can be declared as pointer to const [constParameterPointer] ipcalc-1.0.3/ipcalc.c:1197:39: style: Parameter 'jsonfirst' can be declared as pointer to const [constParameterPointer] ipcalc-1.0.3/ipcalc.c:1204:35: style: Parameter 'jsonfirst' can be declared as pointer to const [constParameterPointer] ipcalc-1.0.3/ipcalc.c:1437:8: style: Variable 'randomStr' can be declared as pointer to const [constVariablePointer] ipcalc-1.0.3/ipcalc.c:1438:8: style: Variable 'hostname' can be declared as pointer to const [constVariablePointer] ipcalc-1.0.3/ipcalc.c:1439:8: style: Variable 'splitStr' can be declared as pointer to const [constVariablePointer] ipcalc-1.0.3/ipcalc.c:1440:42: style: Variable 'netmaskStr' can be declared as pointer to const [constVariablePointer] ipcalc-1.0.3/ipcalc.c:941:26: warning: Uninitialized variable: &network [uninitvar] ipcalc-1.0.3/ipcalc.c:938:16: note: Assuming condition is false ipcalc-1.0.3/ipcalc.c:941:26: note: Uninitialized variable: &network diff: DONE