2024-03-26 19:01 ftp://ftp.de.debian.org/debian/pool/main/c/crazywa/crazywa_0.0.0~git2019.06.13.orig.tar.xz 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 -D__GNUC__ --platform=unix64 -j4 platform: Linux-6.1.0-18-amd64-x86_64-with-glibc2.36 python: 3.11.2 client-version: 1.3.55 compiler: g++ (Debian 12.2.0-14) 12.2.0 cppcheck: head 2.13.0 head-info: 61552d0 (2024-03-26 14:25:53 +0100) count: 56 51 elapsed-time: 9.3 16.9 head-timing-info: old-timing-info: head results: crazywa-0.0.0~git2019.06.13/dropper.c:38:25: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable _SC_CLK_TCK [valueFlowBailoutIncompleteVar] crazywa-0.0.0~git2019.06.13/dropper.c:45:14: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable FIONREAD [valueFlowBailoutIncompleteVar] crazywa-0.0.0~git2019.06.13/dropper.c:1531:25: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable stdout [valueFlowBailoutIncompleteVar] crazywa-0.0.0~git2019.06.13/dropper.c:1847:33: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable EOF [valueFlowBailoutIncompleteVar] crazywa-0.0.0~git2019.06.13/dropper.c:1880:14: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable stdout [valueFlowBailoutIncompleteVar] crazywa-0.0.0~git2019.06.13/dropper.c:1974:12: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable stdout [valueFlowBailoutIncompleteVar] crazywa-0.0.0~git2019.06.13/dropper.c:1277:26: style:inconclusive: Boolean expression 'score>=beta' is used in bitwise operation. Did you mean '&&'? [bitwiseOnBoolean] crazywa-0.0.0~git2019.06.13/dropper.c:1715:30: warning: Either the condition 'inc>0' is redundant or the array 'pieceID[6]' is accessed at index -15, which is out of bounds. [negativeIndex] crazywa-0.0.0~git2019.06.13/dropper.c:1715:10: note: Assuming that condition 'inc>0' is not redundant crazywa-0.0.0~git2019.06.13/dropper.c:1715:30: note: Negative array index crazywa-0.0.0~git2019.06.13/dropper.c:1086:5: error: Found an exit path from function with non-void return type that has missing return statement [missingReturn] crazywa-0.0.0~git2019.06.13/dropper.c:1027:14: style: Boolean result is used in bitwise operation. Clarify expression with parentheses. [clarifyCondition] crazywa-0.0.0~git2019.06.13/dropper.c:1277:26: style: Boolean result is used in bitwise operation. Clarify expression with parentheses. [clarifyCondition] crazywa-0.0.0~git2019.06.13/dropper.c:705:16: style: The if condition is the same as the previous if condition [duplicateCondition] crazywa-0.0.0~git2019.06.13/dropper.c:704:16: note: First condition crazywa-0.0.0~git2019.06.13/dropper.c:705:16: note: Second condition crazywa-0.0.0~git2019.06.13/dropper.c:1953:15: style: Condition '!RootMakeMove(move)' is always false [knownConditionTrueFalse] crazywa-0.0.0~git2019.06.13/dropper.c:1953:28: note: Calling function 'RootMakeMove' returns 1 crazywa-0.0.0~git2019.06.13/dropper.c:1953:15: note: Condition '!RootMakeMove(move)' is always false crazywa-0.0.0~git2019.06.13/dropper.c:1861:5: warning: sscanf() without field width limits can crash with huge input data. [invalidscanf] crazywa-0.0.0~git2019.06.13/dropper.c:1918:10: warning: sscanf() without field width limits can crash with huge input data. [invalidscanf] crazywa-0.0.0~git2019.06.13/dropper.c:1457:60: portability: Shifting a negative value is technically undefined behaviour [shiftNegativeLHS] crazywa-0.0.0~git2019.06.13/dropper.c:1460:60: portability: Shifting a negative value is technically undefined behaviour [shiftNegativeLHS] crazywa-0.0.0~git2019.06.13/dropper.c:1477:63: portability: Shifting a negative value is technically undefined behaviour [shiftNegativeLHS] crazywa-0.0.0~git2019.06.13/dropper.c:1487:39: portability: Shifting a negative value is technically undefined behaviour [shiftNegativeLHS] crazywa-0.0.0~git2019.06.13/dropper.c:1811:42: portability: Shifting a negative value is technically undefined behaviour [shiftNegativeLHS] crazywa-0.0.0~git2019.06.13/dropper.c:646:32: style: Local variable 'c' shadows outer variable [shadowVariable] crazywa-0.0.0~git2019.06.13/dropper.c:533:40: note: Shadowed declaration crazywa-0.0.0~git2019.06.13/dropper.c:646:32: note: Shadow variable crazywa-0.0.0~git2019.06.13/dropper.c:935:8: style: Local variable 'slot' shadows outer variable [shadowVariable] crazywa-0.0.0~git2019.06.13/dropper.c:914:26: note: Shadowed declaration crazywa-0.0.0~git2019.06.13/dropper.c:935:8: note: Shadow variable crazywa-0.0.0~git2019.06.13/dropper.c:945:8: style: Local variable 'slot' shadows outer variable [shadowVariable] crazywa-0.0.0~git2019.06.13/dropper.c:914:26: note: Shadowed declaration crazywa-0.0.0~git2019.06.13/dropper.c:945:8: note: Shadow variable crazywa-0.0.0~git2019.06.13/dropper.c:1149:13: style: Local variable 'stm' shadows outer variable [shadowVariable] crazywa-0.0.0~git2019.06.13/dropper.c:1607:5: note: Shadowed declaration crazywa-0.0.0~git2019.06.13/dropper.c:1149:13: note: Shadow variable crazywa-0.0.0~git2019.06.13/dropper.c:1264:6: style: Local variable 'score' shadows outer variable [shadowVariable] crazywa-0.0.0~git2019.06.13/dropper.c:1239:27: note: Shadowed declaration crazywa-0.0.0~git2019.06.13/dropper.c:1264:6: note: Shadow variable crazywa-0.0.0~git2019.06.13/dropper.c:1390:10: style: Local variable 'score' shadows outer variable [shadowVariable] crazywa-0.0.0~git2019.06.13/dropper.c:1239:27: note: Shadowed declaration crazywa-0.0.0~git2019.06.13/dropper.c:1390:10: note: Shadow variable crazywa-0.0.0~git2019.06.13/dropper.c:1395:23: style: Local variable 'bestNr' shadows outer variable [shadowVariable] crazywa-0.0.0~git2019.06.13/dropper.c:1237:9: note: Shadowed declaration crazywa-0.0.0~git2019.06.13/dropper.c:1395:23: note: Shadow variable crazywa-0.0.0~git2019.06.13/dropper.c:1502:5: style: Local variable 'm' shadows outer variable [shadowVariable] crazywa-0.0.0~git2019.06.13/dropper.c:1234:15: note: Shadowed declaration crazywa-0.0.0~git2019.06.13/dropper.c:1502:5: note: Shadow variable crazywa-0.0.0~git2019.06.13/dropper.c:1646:24: style: Local variable 'stm' shadows outer variable [shadowVariable] crazywa-0.0.0~git2019.06.13/dropper.c:1607:5: note: Shadowed declaration crazywa-0.0.0~git2019.06.13/dropper.c:1646:24: note: Shadow variable crazywa-0.0.0~git2019.06.13/dropper.c:1713:7: style: Local variable 'inc' shadows outer variable [shadowVariable] crazywa-0.0.0~git2019.06.13/dropper.c:81:50: note: Shadowed declaration crazywa-0.0.0~git2019.06.13/dropper.c:1713:7: note: Shadow variable crazywa-0.0.0~git2019.06.13/dropper.c:1977:6: style: Local variable 'i' shadows outer variable [shadowVariable] crazywa-0.0.0~git2019.06.13/dropper.c:1967:14: note: Shadowed declaration crazywa-0.0.0~git2019.06.13/dropper.c:1977:6: note: Shadow variable crazywa-0.0.0~git2019.06.13/dropper.c:229:31: style: Parameter 'codes' can be declared as pointer to const [constParameterPointer] crazywa-0.0.0~git2019.06.13/dropper.c:530:17: style: Parameter 'name' can be declared as pointer to const [constParameterPointer] crazywa-0.0.0~git2019.06.13/dropper.c:710:13: style: Variable 'bulk' can be declared as const array [constVariable] crazywa-0.0.0~git2019.06.13/dropper.c:732:20: style: Parameter 'msg' can be declared as pointer to const [constParameterPointer] crazywa-0.0.0~git2019.06.13/dropper.c:732:40: style: Parameter 'b' can be declared as pointer to const [constParameterPointer] crazywa-0.0.0~git2019.06.13/dropper.c:732:49: style: Parameter 'sep' can be declared as pointer to const [constParameterPointer] crazywa-0.0.0~git2019.06.13/dropper.c:740:20: style: Parameter 'msg' can be declared as pointer to const [constParameterPointer] crazywa-0.0.0~git2019.06.13/dropper.c:740:40: style: Parameter 'p' can be declared as pointer to const [constParameterPointer] crazywa-0.0.0~git2019.06.13/dropper.c:748:20: style: Parameter 'msg' can be declared as pointer to const [constParameterPointer] crazywa-0.0.0~git2019.06.13/dropper.c:748:30: style: Parameter 'p' can be declared as pointer to const [constParameterPointer] crazywa-0.0.0~git2019.06.13/dropper.c:835:16: style: Variable 'rays' can be declared as const array [constVariable] crazywa-0.0.0~git2019.06.13/dropper.c:894:13: style: Parameter 's' can be declared as pointer to const [constParameterPointer] crazywa-0.0.0~git2019.06.13/dropper.c:1019:36: style: Parameter 'f' can be declared as pointer to const [constParameterPointer] crazywa-0.0.0~git2019.06.13/dropper.c:1090:33: style: Parameter 'ff' can be declared as pointer to const [constParameterPointer] crazywa-0.0.0~git2019.06.13/dropper.c:1123:21: style: Parameter 'f' can be declared as pointer to const [constParameterPointer] crazywa-0.0.0~git2019.06.13/dropper.c:1131:23: style: Parameter 'f' can be declared as pointer to const [constParameterPointer] crazywa-0.0.0~git2019.06.13/dropper.c:1211:21: style: Parameter 'f' can be declared as pointer to const [constParameterPointer] crazywa-0.0.0~git2019.06.13/dropper.c:1645:15: style: Variable 'castle' can be declared as const array [constVariable] crazywa-0.0.0~git2019.06.13/dropper.c:1711:24: style: Variable 'pieceID' can be declared as const array [constVariable] crazywa-0.0.0~git2019.06.13/dropper.c:1727:26: style: Parameter 's' can be declared as pointer to const [constParameterPointer] crazywa-0.0.0~git2019.06.13/dropper.c:627:13: style: int result is assigned to long long variable. If the variable is long long to avoid loss of information, then you have loss of information. [truncLongCastAssignment] crazywa-0.0.0~git2019.06.13/dropper.c:822:9: style: struct member 'MoveStack::checker' is never used. [unusedStructMember] crazywa-0.0.0~git2019.06.13/dropper.c:758:12: style: Unused variable: j [unusedVariable] crazywa-0.0.0~git2019.06.13/dropper.c:868:44: style: Variable 'mover' is assigned a value that is never used. [unreadVariable] crazywa-0.0.0~git2019.06.13/dropper.c:914:26: style: Unused variable: slot [unusedVariable] diff: head crazywa-0.0.0~git2019.06.13/dropper.c:1531:25: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable stdout [valueFlowBailoutIncompleteVar] head crazywa-0.0.0~git2019.06.13/dropper.c:1847:33: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable EOF [valueFlowBailoutIncompleteVar] head crazywa-0.0.0~git2019.06.13/dropper.c:1880:14: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable stdout [valueFlowBailoutIncompleteVar] head crazywa-0.0.0~git2019.06.13/dropper.c:1974:12: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable stdout [valueFlowBailoutIncompleteVar] head crazywa-0.0.0~git2019.06.13/dropper.c:45:14: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable FIONREAD [valueFlowBailoutIncompleteVar] DONE