2025-07-10 23:21 ftp://ftp.de.debian.org/debian/pool/main/p/proftpd-mod-statsd/proftpd-mod-statsd_0.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 -j1 platform: Linux-6.8.0-63-generic-x86_64-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: 8f3d36a (2025-07-08 11:07:56 +0200) count: 67 66 elapsed-time: 0.0 0.1 head-timing-info: old-timing-info: head results: proftpd-mod_statsd-0.1/metric.c:35:23: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable FALSE [valueFlowBailoutIncompleteVar] proftpd-mod_statsd-0.1/metric.c:83:12: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable errno [valueFlowBailoutIncompleteVar] proftpd-mod_statsd-0.1/metric.c:97:5: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable errno [valueFlowBailoutIncompleteVar] proftpd-mod_statsd-0.1/metric.c:117:5: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable errno [valueFlowBailoutIncompleteVar] proftpd-mod_statsd-0.1/metric.c:143:5: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable errno [valueFlowBailoutIncompleteVar] proftpd-mod_statsd-0.1/metric.c:139:9: style: Variable 'val_prefix' can be declared as pointer to const [constVariablePointer] proftpd-mod_statsd-0.1/mod_statsd.c:56:23: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable C_QUIT [valueFlowBailoutIncompleteVar] proftpd-mod_statsd-0.1/mod_statsd.c:101:17: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable FALSE [valueFlowBailoutIncompleteVar] proftpd-mod_statsd-0.1/mod_statsd.c:117:12: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable TRUE [valueFlowBailoutIncompleteVar] proftpd-mod_statsd-0.1/mod_statsd.c:144:19: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable CONF_ROOT [valueFlowBailoutIncompleteVar] proftpd-mod_statsd-0.1/mod_statsd.c:206:19: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable CONF_ROOT [valueFlowBailoutIncompleteVar] proftpd-mod_statsd-0.1/mod_statsd.c:236:14: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable STATSD_DEFAULT_PORT [valueFlowBailoutIncompleteVar] proftpd-mod_statsd-0.1/mod_statsd.c:360:40: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable TRUE [valueFlowBailoutIncompleteVar] proftpd-mod_statsd-0.1/mod_statsd.c:390:24: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable FALSE [valueFlowBailoutIncompleteVar] proftpd-mod_statsd-0.1/mod_statsd.c:443:24: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable FALSE [valueFlowBailoutIncompleteVar] proftpd-mod_statsd-0.1/mod_statsd.c:448:24: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable TRUE [valueFlowBailoutIncompleteVar] proftpd-mod_statsd-0.1/mod_statsd.c:463:48: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable conf [valueFlowBailoutIncompleteVar] proftpd-mod_statsd-0.1/mod_statsd.c:498:30: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable CONF_PARAM [valueFlowBailoutIncompleteVar] proftpd-mod_statsd-0.1/mod_statsd.c:528:19: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable FALSE [valueFlowBailoutIncompleteVar] proftpd-mod_statsd-0.1/mod_statsd.c:559:41: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable FALSE [valueFlowBailoutIncompleteVar] proftpd-mod_statsd-0.1/mod_statsd.c:576:41: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable FALSE [valueFlowBailoutIncompleteVar] proftpd-mod_statsd-0.1/mod_statsd.c:596:36: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable pool [valueFlowBailoutIncompleteVar] proftpd-mod_statsd-0.1/mod_statsd.c:627:36: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable pool [valueFlowBailoutIncompleteVar] proftpd-mod_statsd-0.1/mod_statsd.c:655:23: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable FALSE [valueFlowBailoutIncompleteVar] proftpd-mod_statsd-0.1/mod_statsd.c:541:11: style: Condition 'res<0' is always false [knownConditionTrueFalse] proftpd-mod_statsd-0.1/mod_statsd.c:540:25: note: Calling function 'statsd_sess_init' returns 0 proftpd-mod_statsd-0.1/mod_statsd.c:540:25: note: Assignment 'res=statsd_sess_init()', assigned value is 0 proftpd-mod_statsd-0.1/mod_statsd.c:541:11: note: Condition 'res<0' is always false proftpd-mod_statsd-0.1/mod_statsd.c:100:36: style: Parameter 'cmd' can be declared as pointer to const [constParameterPointer] proftpd-mod_statsd-0.1/mod_statsd.c:323:9: style: Variable 'handshake_metric' can be declared as pointer to const [constVariablePointer] proftpd-mod_statsd-0.1/mod_statsd.c:323:28: style: Variable 'proto_metric' can be declared as pointer to const [constVariablePointer] proftpd-mod_statsd-0.1/mod_statsd.c:342:11: style: Variable 'cipher_metric' can be declared as pointer to const [constVariablePointer] proftpd-mod_statsd-0.1/mod_statsd.c:351:11: style: Variable 'protocol_metric' can be declared as pointer to const [constVariablePointer] proftpd-mod_statsd-0.1/mod_statsd.c:366:11: style: Variable 'tls_mode' can be declared as pointer to const [constVariablePointer] proftpd-mod_statsd-0.1/mod_statsd.c:386:9: style: Variable 'metric' can be declared as pointer to const [constVariablePointer] proftpd-mod_statsd-0.1/mod_statsd.c:428:13: style: Variable 'proto_metric' can be declared as pointer to const [constVariablePointer] proftpd-mod_statsd-0.1/mod_statsd.c:457:11: style: Variable 'metric' can be declared as pointer to const [constVariablePointer] proftpd-mod_statsd-0.1/mod_statsd.c:458:20: style: Variable 'authenticated' can be declared as pointer to const [constVariablePointer] proftpd-mod_statsd-0.1/mod_statsd.c:557:9: style: Variable 'proto_metric' can be declared as pointer to const [constVariablePointer] proftpd-mod_statsd-0.1/mod_statsd.c:574:9: style: Variable 'proto_metric' can be declared as pointer to const [constVariablePointer] proftpd-mod_statsd-0.1/mod_statsd.c:590:9: style: Variable 'metric' can be declared as pointer to const [constVariablePointer] proftpd-mod_statsd-0.1/mod_statsd.c:603:66: style: Parameter 'user_data' can be declared as pointer to const. However it seems that 'statsd_timeout_idle_ev' is a callback function, if 'user_data' is declared with const you might also need to cast function pointer(s). [constParameterCallback] proftpd-mod_statsd-0.1/mod_statsd.c:729:5: note: You might need to cast the function pointer here proftpd-mod_statsd-0.1/mod_statsd.c:603:66: note: Parameter 'user_data' can be declared as pointer to const proftpd-mod_statsd-0.1/mod_statsd.c:607:67: style: Parameter 'user_data' can be declared as pointer to const. However it seems that 'statsd_timeout_login_ev' is a callback function, if 'user_data' is declared with const you might also need to cast function pointer(s). [constParameterCallback] proftpd-mod_statsd-0.1/mod_statsd.c:731:5: note: You might need to cast the function pointer here proftpd-mod_statsd-0.1/mod_statsd.c:607:67: note: Parameter 'user_data' can be declared as pointer to const proftpd-mod_statsd-0.1/mod_statsd.c:611:68: style: Parameter 'user_data' can be declared as pointer to const. However it seems that 'statsd_timeout_noxfer_ev' is a callback function, if 'user_data' is declared with const you might also need to cast function pointer(s). [constParameterCallback] proftpd-mod_statsd-0.1/mod_statsd.c:733:5: note: You might need to cast the function pointer here proftpd-mod_statsd-0.1/mod_statsd.c:611:68: note: Parameter 'user_data' can be declared as pointer to const proftpd-mod_statsd-0.1/mod_statsd.c:615:69: style: Parameter 'user_data' can be declared as pointer to const. However it seems that 'statsd_timeout_session_ev' is a callback function, if 'user_data' is declared with const you might also need to cast function pointer(s). [constParameterCallback] proftpd-mod_statsd-0.1/mod_statsd.c:735:5: note: You might need to cast the function pointer here proftpd-mod_statsd-0.1/mod_statsd.c:615:69: note: Parameter 'user_data' can be declared as pointer to const proftpd-mod_statsd-0.1/mod_statsd.c:619:69: style: Parameter 'user_data' can be declared as pointer to const. However it seems that 'statsd_timeout_stalled_ev' is a callback function, if 'user_data' is declared with const you might also need to cast function pointer(s). [constParameterCallback] proftpd-mod_statsd-0.1/mod_statsd.c:737:5: note: You might need to cast the function pointer here proftpd-mod_statsd-0.1/mod_statsd.c:619:69: note: Parameter 'user_data' can be declared as pointer to const proftpd-mod_statsd-0.1/mod_statsd.c:625:9: style: Variable 'metric' can be declared as pointer to const [constVariablePointer] proftpd-mod_statsd-0.1/mod_statsd.c:640:11: style: Parameter 'user_data' can be declared as pointer to const. However it seems that 'statsd_tls_ctrl_handshake_error_ev' is a callback function, if 'user_data' is declared with const you might also need to cast function pointer(s). [constParameterCallback] proftpd-mod_statsd-0.1/mod_statsd.c:748:7: note: You might need to cast the function pointer here proftpd-mod_statsd-0.1/mod_statsd.c:640:11: note: Parameter 'user_data' can be declared as pointer to const proftpd-mod_statsd-0.1/mod_statsd.c:645:11: style: Parameter 'user_data' can be declared as pointer to const. However it seems that 'statsd_tls_data_handshake_error_ev' is a callback function, if 'user_data' is declared with const you might also need to cast function pointer(s). [constParameterCallback] proftpd-mod_statsd-0.1/mod_statsd.c:750:7: note: You might need to cast the function pointer here proftpd-mod_statsd-0.1/mod_statsd.c:645:11: note: Parameter 'user_data' can be declared as pointer to const proftpd-mod_statsd-0.1/mod_statsd.c:654:16: style: Variable 'metric' can be declared as pointer to const [constVariablePointer] proftpd-mod_statsd-0.1/mod_statsd.c:654:25: style: Variable 'prefix' can be declared as pointer to const [constVariablePointer] proftpd-mod_statsd-0.1/mod_statsd.c:654:41: style: Variable 'suffix' can be declared as pointer to const [constVariablePointer] proftpd-mod_statsd-0.1/statsd.c:62:5: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable errno [valueFlowBailoutIncompleteVar] proftpd-mod_statsd-0.1/statsd.c:132:5: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable errno [valueFlowBailoutIncompleteVar] proftpd-mod_statsd-0.1/statsd.c:149:5: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable errno [valueFlowBailoutIncompleteVar] proftpd-mod_statsd-0.1/statsd.c:172:5: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable errno [valueFlowBailoutIncompleteVar] proftpd-mod_statsd-0.1/statsd.c:181:5: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable errno [valueFlowBailoutIncompleteVar] proftpd-mod_statsd-0.1/statsd.c:190:5: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable errno [valueFlowBailoutIncompleteVar] proftpd-mod_statsd-0.1/statsd.c:204:12: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable TRUE [valueFlowBailoutIncompleteVar] proftpd-mod_statsd-0.1/statsd.c:249:5: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable errno [valueFlowBailoutIncompleteVar] proftpd-mod_statsd-0.1/statsd.c:312:5: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable errno [valueFlowBailoutIncompleteVar] proftpd-mod_statsd-0.1/statsd.c:328:9: portability: Non reentrant function 'getprotobyname' called. For threadsafe applications it is recommended to use the reentrant replacement function 'getprotobyname_r'. [prohibitedgetprotobynameCalled] proftpd-mod_statsd-0.1/statsd.c:333:9: portability: Non reentrant function 'getprotobyname' called. For threadsafe applications it is recommended to use the reentrant replacement function 'getprotobyname_r'. [prohibitedgetprotobynameCalled] proftpd-mod_statsd-0.1/statsd.c:263:23: style: The if condition is the same as the previous if condition [duplicateCondition] proftpd-mod_statsd-0.1/statsd.c:256:23: note: First condition proftpd-mod_statsd-0.1/statsd.c:263:23: note: Second condition proftpd-mod_statsd-0.1/statsd.c:145:50: style: Parameter 'statsd' can be declared as pointer to const [constParameterPointer] proftpd-mod_statsd-0.1/statsd.c:170:45: style: Parameter 'statsd' can be declared as pointer to const [constParameterPointer] proftpd-mod_statsd-0.1/statsd.c:179:49: style: Parameter 'statsd' can be declared as pointer to const [constParameterPointer] proftpd-mod_statsd-0.1/statsd.c:322:20: style: Variable 'pre' can be declared as pointer to const [constVariablePointer] proftpd-mod_statsd-0.1/t/api/tests.h:35:0: error: #error "Missing Check installation; necessary for ProFTPD testsuite" [preprocessorErrorDirective] proftpd-mod_statsd-0.1/t/api/tests.h:35:3: error: #error "Missing Check installation; necessary for ProFTPD testsuite" [preprocessorErrorDirective] diff: head proftpd-mod_statsd-0.1/t/api/tests.h:35:3: error: #error "Missing Check installation; necessary for ProFTPD testsuite" [preprocessorErrorDirective] DONE