2025-01-28 04:40 ftp://ftp.de.debian.org/debian/pool/main/f/fping/fping_5.1.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-1016-oracle-aarch64-with-glibc2.39 python: 3.12.3 client-version: 1.3.59 compiler: g++ (Ubuntu 13.3.0-6ubuntu2~24.04) 13.3.0 cppcheck: head 2.16.0 head-info: b9644e7 (2025-01-27 23:14:41 +0100) count: 70 70 elapsed-time: 0.9 0.4 head-timing-info: old-timing-info: head results: fping-5.1/src/seqmap.c:76:17: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable stderr [valueFlowBailoutIncompleteVar] fping-5.1/src/seqmap.c:84:9: warning: %d in format string (no. 2) requires 'int' but the argument type is 'unsigned int'. [invalidPrintfArgType_sint] fping-5.1/src/seqmap.c:84:9: warning: %d in format string (no. 3) requires 'int' but the argument type is 'unsigned int'. [invalidPrintfArgType_sint] fping-5.1/src/seqmap.c:84:9: warning: %d in format string (no. 4) requires 'int' but the argument type is 'unsigned int'. [invalidPrintfArgType_sint] fping-5.1/src/seqmap.c:70:80: style:inconclusive: Function 'seqmap_add' argument 3 names different: declaration 'now' definition 'timestamp'. [funcArgNamesDifferent] fping-5.1/src/seqmap.h:18:80: note: Function 'seqmap_add' argument 3 names different: declaration 'now' definition 'timestamp'. fping-5.1/src/seqmap.c:70:80: note: Function 'seqmap_add' argument 3 names different: declaration 'now' definition 'timestamp'. fping-5.1/src/socket4.c:60:17: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable SOCK_RAW [valueFlowBailoutIncompleteVar] fping-5.1/src/socket4.c:88:43: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable ICMP_MINLEN [valueFlowBailoutIncompleteVar] fping-5.1/src/socket4.c:100:21: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable AF_INET [valueFlowBailoutIncompleteVar] fping-5.1/src/socket4.c:139:22: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable ICMP_ECHO [valueFlowBailoutIncompleteVar] fping-5.1/src/socket4.c:56:18: portability: Non reentrant function 'getprotobyname' called. For threadsafe applications it is recommended to use the reentrant replacement function 'getprotobyname_r'. [prohibitedgetprotobynameCalled] fping-5.1/src/socket4.c:61:36: warning: Either the condition '(proto=getprotobyname("icmp"))==NULL' is redundant or there is possible null pointer dereference: proto. [nullPointerRedundantCheck] fping-5.1/src/socket4.c:56:42: note: Assuming that condition '(proto=getprotobyname("icmp"))==NULL' is not redundant fping-5.1/src/socket4.c:61:36: note: Null pointer dereference fping-5.1/src/socket4.c:132:90: style:inconclusive: Function 'socket_sendto_ping_ipv4' argument 4 names different: declaration 'icmp_seq' definition 'icmp_seq_nr'. [funcArgNamesDifferent] fping-5.1/src/fping.h:31:91: note: Function 'socket_sendto_ping_ipv4' argument 4 names different: declaration 'icmp_seq' definition 'icmp_seq_nr'. fping-5.1/src/socket4.c:132:90: note: Function 'socket_sendto_ping_ipv4' argument 4 names different: declaration 'icmp_seq' definition 'icmp_seq_nr'. fping-5.1/src/socket4.c:132:112: style:inconclusive: Function 'socket_sendto_ping_ipv4' argument 5 names different: declaration 'icmp_id' definition 'icmp_id_nr'. [funcArgNamesDifferent] fping-5.1/src/fping.h:31:110: note: Function 'socket_sendto_ping_ipv4' argument 5 names different: declaration 'icmp_id' definition 'icmp_id_nr'. fping-5.1/src/socket4.c:132:112: note: Function 'socket_sendto_ping_ipv4' argument 5 names different: declaration 'icmp_id' definition 'icmp_id_nr'. fping-5.1/src/socket4.c:94:54: style: Parameter 'src_addr' can be declared as pointer to const [constParameterPointer] fping-5.1/src/socket4.c:115:40: style: Parameter 'buffer' can be declared as pointer to const [constParameterPointer] fping-5.1/src/socket4.c:132:53: style: Parameter 'saddr' can be declared as pointer to const [constParameterPointer] fping-5.1/src/optparse.c:104:14: style: Variable 'str' can be declared as const array [constVariable] fping-5.1/src/optparse.c:125:18: style: Variable 'str' can be declared as const array [constVariable] fping-5.1/src/socket6.c:59:17: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable SOCK_RAW [valueFlowBailoutIncompleteVar] fping-5.1/src/socket6.c:87:57: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable icmp6_hdr [valueFlowBailoutIncompleteVar] fping-5.1/src/socket6.c:99:22: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable AF_INET6 [valueFlowBailoutIncompleteVar] fping-5.1/src/socket6.c:120:23: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable ICMP6_ECHO_REQUEST [valueFlowBailoutIncompleteVar] fping-5.1/src/socket6.c:55:18: portability: Non reentrant function 'getprotobyname' called. For threadsafe applications it is recommended to use the reentrant replacement function 'getprotobyname_r'. [prohibitedgetprotobynameCalled] fping-5.1/src/socket6.c:60:37: warning: Either the condition '(proto=getprotobyname("ipv6-icmp"))==NULL' is redundant or there is possible null pointer dereference: proto. [nullPointerRedundantCheck] fping-5.1/src/socket6.c:55:47: note: Assuming that condition '(proto=getprotobyname("ipv6-icmp"))==NULL' is not redundant fping-5.1/src/socket6.c:60:37: note: Null pointer dereference fping-5.1/src/socket6.c:93:55: style: Parameter 'src_addr' can be declared as pointer to const [constParameterPointer] fping-5.1/src/socket6.c:114:53: style: Parameter 'saddr' can be declared as pointer to const [constParameterPointer] fping-5.1/src/fping.c:546:68: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable EOF [valueFlowBailoutIncompleteVar] fping-5.1/src/fping.c:1197:28: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable AF_UNSPEC [valueFlowBailoutIncompleteVar] fping-5.1/src/fping.c:1251:28: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable AF_UNSPEC [valueFlowBailoutIncompleteVar] fping-5.1/src/fping.c:1503:19: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable CLOCK_REALTIME [valueFlowBailoutIncompleteVar] fping-5.1/src/fping.c:1596:17: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable stderr [valueFlowBailoutIncompleteVar] fping-5.1/src/fping.c:1703:34: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable PRId64 [valueFlowBailoutIncompleteVar] fping-5.1/src/fping.c:1735:17: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable stderr [valueFlowBailoutIncompleteVar] fping-5.1/src/fping.c:1788:13: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable stderr [valueFlowBailoutIncompleteVar] fping-5.1/src/fping.c:1866:83: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable errno [valueFlowBailoutIncompleteVar] fping-5.1/src/fping.c:1916:13: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable errno [valueFlowBailoutIncompleteVar] fping-5.1/src/fping.c:2102:32: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable ICMP_MINLEN [valueFlowBailoutIncompleteVar] fping-5.1/src/fping.c:2308:36: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable AF_INET [valueFlowBailoutIncompleteVar] fping-5.1/src/fping.c:2486:25: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable SOCK_RAW [valueFlowBailoutIncompleteVar] fping-5.1/src/fping.c:2649:17: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable stderr [valueFlowBailoutIncompleteVar] fping-5.1/src/fping.c:2668:13: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable stderr [valueFlowBailoutIncompleteVar] fping-5.1/src/fping.c:2685:18: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable stderr [valueFlowBailoutIncompleteVar] fping-5.1/src/fping.c:2744:29: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable AF_INET [valueFlowBailoutIncompleteVar] fping-5.1/src/fping.c:2899:37: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable stdout [valueFlowBailoutIncompleteVar] fping-5.1/src/fping.c:1738:15: portability: Non reentrant function 'localtime' called. For threadsafe applications it is recommended to use the reentrant replacement function 'localtime_r'. [prohibitedlocaltimeCalled] fping-5.1/src/fping.c:1560:13: warning: %d in format string (no. 1) requires 'int' but the argument type is 'unsigned int'. [invalidPrintfArgType_sint] fping-5.1/src/fping.c:1563:13: warning: %d in format string (no. 1) requires 'int' but the argument type is 'unsigned int'. [invalidPrintfArgType_sint] fping-5.1/src/fping.c:1076:17: warning: sscanf() without field width limits can crash with huge input data. [invalidscanf] fping-5.1/src/fping.c:1269:48: error: Memory leak: addr_res [memleak] fping-5.1/src/fping.c:1125:21: style: Redundant initialization for 'cursor'. The initialized value is overwritten before it is read. [redundantInitialization] fping-5.1/src/fping.c:1118:30: note: cursor is initialized fping-5.1/src/fping.c:1125:21: note: cursor is overwritten fping-5.1/src/fping.c:2680:26: style:inconclusive: Function 'print_warning' argument 1 names different: declaration 'fmt' definition 'format'. [funcArgNamesDifferent] fping-5.1/src/fping.c:391:26: note: Function 'print_warning' argument 1 names different: declaration 'fmt' definition 'format'. fping-5.1/src/fping.c:2680:26: note: Function 'print_warning' argument 1 names different: declaration 'fmt' definition 'format'. fping-5.1/src/fping.c:2701:31: style:inconclusive: Function 'sprint_tm' argument 1 names different: declaration 't' definition 'ns'. [funcArgNamesDifferent] fping-5.1/src/fping.c:385:31: note: Function 'sprint_tm' argument 1 names different: declaration 't' definition 'ns'. fping-5.1/src/fping.c:2701:31: note: Function 'sprint_tm' argument 1 names different: declaration 't' definition 'ns'. fping-5.1/src/fping.c:1169:52: style: Parameter 'a' can be declared as pointer to const [constParameterPointer] fping-5.1/src/fping.c:1174:21: style: Parameter 'addr' can be declared as pointer to const [constParameterPointer] fping-5.1/src/fping.c:1177:11: style: Variable 'mask_str' can be declared as pointer to const [constVariablePointer] fping-5.1/src/fping.c:1241:22: style: Parameter 'start' can be declared as pointer to const [constParameterPointer] fping-5.1/src/fping.c:1241:35: style: Parameter 'end' can be declared as pointer to const [constParameterPointer] fping-5.1/src/fping.c:1525:17: style: Variable 'h' can be declared as pointer to const [constVariablePointer] fping-5.1/src/fping.c:1592:17: style: Variable 'h' can be declared as pointer to const [constVariablePointer] fping-5.1/src/fping.c:1732:16: style: Variable 'curr_tm' can be declared as pointer to const [constVariablePointer] fping-5.1/src/fping.c:2077:22: style: Parameter 'response_addr' can be declared as pointer to const [constParameterPointer] fping-5.1/src/fping.c:2088:20: style: Variable 'ip' can be declared as pointer to const [constVariablePointer] fping-5.1/src/fping.c:2116:22: style: Variable 'sent_icmp' can be declared as pointer to const [constVariablePointer] fping-5.1/src/fping.c:2117:23: style: Variable 'seqmap_value' can be declared as pointer to const [constVariablePointer] fping-5.1/src/fping.c:2287:19: style: Variable 'seqmap_value' can be declared as pointer to const [constVariablePointer] fping-5.1/src/fping.c:2583:21: style: Parameter 'name' can be declared as pointer to const [constParameterPointer] fping-5.1/src/fping.c:2583:33: style: Parameter 'host' can be declared as pointer to const [constParameterPointer] fping-5.1/src/fping.c:2583:56: style: Parameter 'ipaddr' can be declared as pointer to const [constParameterPointer] fping-5.1/src/fping.c:2646:27: style: Parameter 'message' can be declared as pointer to const [constParameterPointer] fping-5.1/src/fping.c:2666:33: style: Parameter 'message' can be declared as pointer to const [constParameterPointer] diff: 2.16.0 fping-5.1/src/fping.c:1197:28: debug: analyzeConditionExpressions bailout: Skipping function due to incomplete variable AF_UNSPEC [valueFlowBailoutIncompleteVar] head fping-5.1/src/fping.c:1197:28: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable AF_UNSPEC [valueFlowBailoutIncompleteVar] 2.16.0 fping-5.1/src/fping.c:1251:28: debug: analyzeConditionExpressions bailout: Skipping function due to incomplete variable AF_UNSPEC [valueFlowBailoutIncompleteVar] head fping-5.1/src/fping.c:1251:28: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable AF_UNSPEC [valueFlowBailoutIncompleteVar] 2.16.0 fping-5.1/src/fping.c:1503:19: debug: analyzeConditionExpressions bailout: Skipping function due to incomplete variable CLOCK_REALTIME [valueFlowBailoutIncompleteVar] head fping-5.1/src/fping.c:1503:19: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable CLOCK_REALTIME [valueFlowBailoutIncompleteVar] 2.16.0 fping-5.1/src/fping.c:1596:17: debug: analyzeConditionExpressions bailout: Skipping function due to incomplete variable stderr [valueFlowBailoutIncompleteVar] head fping-5.1/src/fping.c:1596:17: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable stderr [valueFlowBailoutIncompleteVar] 2.16.0 fping-5.1/src/fping.c:1703:34: debug: analyzeConditionExpressions bailout: Skipping function due to incomplete variable PRId64 [valueFlowBailoutIncompleteVar] head fping-5.1/src/fping.c:1703:34: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable PRId64 [valueFlowBailoutIncompleteVar] 2.16.0 fping-5.1/src/fping.c:1735:17: debug: analyzeConditionExpressions bailout: Skipping function due to incomplete variable stderr [valueFlowBailoutIncompleteVar] head fping-5.1/src/fping.c:1735:17: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable stderr [valueFlowBailoutIncompleteVar] 2.16.0 fping-5.1/src/fping.c:1788:13: debug: analyzeConditionExpressions bailout: Skipping function due to incomplete variable stderr [valueFlowBailoutIncompleteVar] head fping-5.1/src/fping.c:1788:13: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable stderr [valueFlowBailoutIncompleteVar] 2.16.0 fping-5.1/src/fping.c:1866:83: debug: analyzeConditionExpressions bailout: Skipping function due to incomplete variable errno [valueFlowBailoutIncompleteVar] head fping-5.1/src/fping.c:1866:83: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable errno [valueFlowBailoutIncompleteVar] 2.16.0 fping-5.1/src/fping.c:1916:13: debug: analyzeConditionExpressions bailout: Skipping function due to incomplete variable errno [valueFlowBailoutIncompleteVar] head fping-5.1/src/fping.c:1916:13: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable errno [valueFlowBailoutIncompleteVar] 2.16.0 fping-5.1/src/fping.c:2102:32: debug: analyzeConditionExpressions bailout: Skipping function due to incomplete variable ICMP_MINLEN [valueFlowBailoutIncompleteVar] head fping-5.1/src/fping.c:2102:32: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable ICMP_MINLEN [valueFlowBailoutIncompleteVar] 2.16.0 fping-5.1/src/fping.c:2308:36: debug: analyzeConditionExpressions bailout: Skipping function due to incomplete variable AF_INET [valueFlowBailoutIncompleteVar] head fping-5.1/src/fping.c:2308:36: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable AF_INET [valueFlowBailoutIncompleteVar] 2.16.0 fping-5.1/src/fping.c:2486:25: debug: analyzeConditionExpressions bailout: Skipping function due to incomplete variable SOCK_RAW [valueFlowBailoutIncompleteVar] head fping-5.1/src/fping.c:2486:25: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable SOCK_RAW [valueFlowBailoutIncompleteVar] 2.16.0 fping-5.1/src/fping.c:2649:17: debug: analyzeConditionExpressions bailout: Skipping function due to incomplete variable stderr [valueFlowBailoutIncompleteVar] head fping-5.1/src/fping.c:2649:17: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable stderr [valueFlowBailoutIncompleteVar] 2.16.0 fping-5.1/src/fping.c:2668:13: debug: analyzeConditionExpressions bailout: Skipping function due to incomplete variable stderr [valueFlowBailoutIncompleteVar] head fping-5.1/src/fping.c:2668:13: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable stderr [valueFlowBailoutIncompleteVar] 2.16.0 fping-5.1/src/fping.c:2685:18: debug: analyzeConditionExpressions bailout: Skipping function due to incomplete variable stderr [valueFlowBailoutIncompleteVar] head fping-5.1/src/fping.c:2685:18: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable stderr [valueFlowBailoutIncompleteVar] 2.16.0 fping-5.1/src/fping.c:2744:29: debug: analyzeConditionExpressions bailout: Skipping function due to incomplete variable AF_INET [valueFlowBailoutIncompleteVar] head fping-5.1/src/fping.c:2744:29: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable AF_INET [valueFlowBailoutIncompleteVar] 2.16.0 fping-5.1/src/fping.c:2899:37: debug: analyzeConditionExpressions bailout: Skipping function due to incomplete variable stdout [valueFlowBailoutIncompleteVar] head fping-5.1/src/fping.c:2899:37: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable stdout [valueFlowBailoutIncompleteVar] 2.16.0 fping-5.1/src/fping.c:546:68: debug: analyzeConditionExpressions bailout: Skipping function due to incomplete variable EOF [valueFlowBailoutIncompleteVar] head fping-5.1/src/fping.c:546:68: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable EOF [valueFlowBailoutIncompleteVar] 2.16.0 fping-5.1/src/seqmap.c:76:17: debug: analyzeConditionExpressions bailout: Skipping function due to incomplete variable stderr [valueFlowBailoutIncompleteVar] head fping-5.1/src/seqmap.c:76:17: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable stderr [valueFlowBailoutIncompleteVar] 2.16.0 fping-5.1/src/socket4.c:100:21: debug: analyzeConditionExpressions bailout: Skipping function due to incomplete variable AF_INET [valueFlowBailoutIncompleteVar] head fping-5.1/src/socket4.c:100:21: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable AF_INET [valueFlowBailoutIncompleteVar] 2.16.0 fping-5.1/src/socket4.c:139:22: debug: analyzeConditionExpressions bailout: Skipping function due to incomplete variable ICMP_ECHO [valueFlowBailoutIncompleteVar] head fping-5.1/src/socket4.c:139:22: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable ICMP_ECHO [valueFlowBailoutIncompleteVar] 2.16.0 fping-5.1/src/socket4.c:60:17: debug: analyzeConditionExpressions bailout: Skipping function due to incomplete variable SOCK_RAW [valueFlowBailoutIncompleteVar] head fping-5.1/src/socket4.c:60:17: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable SOCK_RAW [valueFlowBailoutIncompleteVar] 2.16.0 fping-5.1/src/socket4.c:88:43: debug: analyzeConditionExpressions bailout: Skipping function due to incomplete variable ICMP_MINLEN [valueFlowBailoutIncompleteVar] head fping-5.1/src/socket4.c:88:43: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable ICMP_MINLEN [valueFlowBailoutIncompleteVar] 2.16.0 fping-5.1/src/socket6.c:120:23: debug: analyzeConditionExpressions bailout: Skipping function due to incomplete variable ICMP6_ECHO_REQUEST [valueFlowBailoutIncompleteVar] head fping-5.1/src/socket6.c:120:23: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable ICMP6_ECHO_REQUEST [valueFlowBailoutIncompleteVar] 2.16.0 fping-5.1/src/socket6.c:59:17: debug: analyzeConditionExpressions bailout: Skipping function due to incomplete variable SOCK_RAW [valueFlowBailoutIncompleteVar] head fping-5.1/src/socket6.c:59:17: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable SOCK_RAW [valueFlowBailoutIncompleteVar] 2.16.0 fping-5.1/src/socket6.c:87:57: debug: analyzeConditionExpressions bailout: Skipping function due to incomplete variable icmp6_hdr [valueFlowBailoutIncompleteVar] head fping-5.1/src/socket6.c:87:57: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable icmp6_hdr [valueFlowBailoutIncompleteVar] 2.16.0 fping-5.1/src/socket6.c:99:22: debug: analyzeConditionExpressions bailout: Skipping function due to incomplete variable AF_INET6 [valueFlowBailoutIncompleteVar] head fping-5.1/src/socket6.c:99:22: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable AF_INET6 [valueFlowBailoutIncompleteVar] DONE