2022-06-24 14:16 ftp://ftp.de.debian.org/debian/pool/main/p/ptouch-driver/ptouch-driver_1.6.orig.tar.gz cppcheck-options: --library=posix --library=gnu --showtime=top5 --check-library --inconclusive --enable=style,information --template=daca2 -D__GNUC__ --platform=unix64 -rp=temp -j2 platform: Linux-5.4.0-110-generic-x86_64-with-glibc2.29 python: 3.8.10 client-version: 1.3.24 compiler: g++ (Ubuntu 9.4.0-1ubuntu1~20.04.1) 9.4.0 cppcheck: head 2.8 head-info: 11860cc (2022-06-24 13:55:04 +0200) count: 19 20 elapsed-time: 5.9 6.1 head-timing-info: Overall time: 0s old-timing-info: Overall time: 0s head results: printer-driver-ptouch-1.6/ptexplain.c:636:4: warning: %u in format string (no. 1) requires 'unsigned int' but the argument type is 'signed int'. [invalidPrintfArgType_uint] printer-driver-ptouch-1.6/ptexplain.c:674:6: style: Variable 'd' is assigned a value that is never used. [unreadVariable] printer-driver-ptouch-1.6/ptexplain.c:685:6: style: Variable 'd' is assigned a value that is never used. [unreadVariable] printer-driver-ptouch-1.6/ptexplain.c:690:6: style: Variable 'd' is assigned a value that is never used. [unreadVariable] printer-driver-ptouch-1.6/rastertoptch.c:532:11: style: The if condition is the same as the previous if condition [duplicateCondition] printer-driver-ptouch-1.6/rastertoptch.c:526:11: note: First condition printer-driver-ptouch-1.6/rastertoptch.c:532:11: note: Second condition printer-driver-ptouch-1.6/rastertoptch.c:821:2: warning: %u in format string (no. 1) requires 'unsigned int' but the argument type is 'signed int'. [invalidPrintfArgType_uint] printer-driver-ptouch-1.6/rastertoptch.c:1112:9: portability: %ld in format string (no. 1) requires 'long' but the argument type is 'size_t {aka unsigned long}'. [invalidPrintfArgType_sint] printer-driver-ptouch-1.6/rastertoptch.c:1112:9: portability: %ld in format string (no. 2) requires 'long' but the argument type is 'size_t {aka unsigned long}'. [invalidPrintfArgType_sint] printer-driver-ptouch-1.6/rastertoptch.c:1555:5: warning: %d in format string (no. 1) requires 'int' but the argument type is 'unsigned int'. [invalidPrintfArgType_sint] printer-driver-ptouch-1.6/rastertoptch.c:557:27: warning: Either the condition 'value' is redundant or there is possible null pointer dereference: value. [nullPointerRedundantCheck] printer-driver-ptouch-1.6/rastertoptch.c:547:6: note: Assuming that condition 'value' is not redundant printer-driver-ptouch-1.6/rastertoptch.c:557:27: note: Null pointer dereference printer-driver-ptouch-1.6/rastertoptch.c:590:27: warning: Either the condition 'value' is redundant or there is possible null pointer dereference: value. [nullPointerRedundantCheck] printer-driver-ptouch-1.6/rastertoptch.c:580:6: note: Assuming that condition 'value' is not redundant printer-driver-ptouch-1.6/rastertoptch.c:590:27: note: Null pointer dereference printer-driver-ptouch-1.6/rastertoptch.c:491:7: style: Consecutive return, break, continue, goto or throw statements are unnecessary. [duplicateBreak] printer-driver-ptouch-1.6/rastertoptch.c:507:7: style: Consecutive return, break, continue, goto or throw statements are unnecessary. [duplicateBreak] printer-driver-ptouch-1.6/rastertoptch.c:523:7: style: Consecutive return, break, continue, goto or throw statements are unnecessary. [duplicateBreak] printer-driver-ptouch-1.6/rastertoptch.c:541:7: style: Consecutive return, break, continue, goto or throw statements are unnecessary. [duplicateBreak] printer-driver-ptouch-1.6/rastertoptch.c:330:8: style: Local variable 'buffer' shadows outer variable [shadowVariable] printer-driver-ptouch-1.6/rastertoptch.c:306:16: note: Shadowed declaration printer-driver-ptouch-1.6/rastertoptch.c:330:8: note: Shadow variable printer-driver-ptouch-1.6/rastertoptch.c:949:36: style: Parameter 'in_buffer' can be declared as pointer to const [constParameter] printer-driver-ptouch-1.6/rastertoptch.c:1339:9: style: Variable 'pt2px' can be declared as const array [constVariable] printer-driver-ptouch-1.6/rastertoptch.c:1490:11: style: Variable 'pt2px' can be declared as const array [constVariable] diff: 2.8 printer-driver-ptouch-1.6/ptexplain.c:456:41: style: Parameter 'end' can be declared with const [constParameter] head printer-driver-ptouch-1.6/rastertoptch.c:1339:9: style: Variable 'pt2px' can be declared as const array [constVariable] 2.8 printer-driver-ptouch-1.6/rastertoptch.c:1339:9: style: Variable 'pt2px' can be declared with const [constVariable] head printer-driver-ptouch-1.6/rastertoptch.c:1490:11: style: Variable 'pt2px' can be declared as const array [constVariable] 2.8 printer-driver-ptouch-1.6/rastertoptch.c:1490:11: style: Variable 'pt2px' can be declared with const [constVariable] head printer-driver-ptouch-1.6/rastertoptch.c:949:36: style: Parameter 'in_buffer' can be declared as pointer to const [constParameter] 2.8 printer-driver-ptouch-1.6/rastertoptch.c:949:36: style: Parameter 'in_buffer' can be declared with const [constParameter] DONE