2024-04-06 21:13 ftp://ftp.de.debian.org/debian/pool/main/f/fosfat/fosfat_0.4.0-13-ged091bb.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 -j1 platform: Linux-5.15.0-101-generic-x86_64-with-glibc2.35 python: 3.10.12 client-version: 1.3.55 compiler: g++ (Ubuntu 12.3.0-1ubuntu1~22.04) 12.3.0 cppcheck: head 2.13.0 head-info: c15004e (2024-04-06 15:16:59 +0200) count: 34 28 elapsed-time: 5.0 5.6 head-timing-info: old-timing-info: head results: fosfat-0.4.0-13-ged091bb/fosmount/fosmount.c:562:11: error: There is an unknown macro here somewhere. Configuration is required. If LIBFOSFAT_VERSION_STR is a macro then please configure it. [unknownMacro] fosfat-0.4.0-13-ged091bb/libfosfat/fosfat.c:429:12: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable stderr [valueFlowBailoutIncompleteVar] fosfat-0.4.0-13-ged091bb/libfosfat/fosfat.c:1114:18: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable stdout [valueFlowBailoutIncompleteVar] fosfat-0.4.0-13-ged091bb/libfosfat/fosfat.c:1265:14: portability: Non reentrant function 'strtok' called. For threadsafe applications it is recommended to use the reentrant replacement function 'strtok_r'. [prohibitedstrtokCalled] fosfat-0.4.0-13-ged091bb/libfosfat/fosfat.c:1268:19: portability: Non reentrant function 'strtok' called. For threadsafe applications it is recommended to use the reentrant replacement function 'strtok_r'. [prohibitedstrtokCalled] fosfat-0.4.0-13-ged091bb/libfosfat/fosfat.c:1108:50: style: Condition 'file_d=file_d->next_data' is always true [knownConditionTrueFalse] fosfat-0.4.0-13-ged091bb/libfosfat/fosfat.c:1117:40: style: Condition 'file=file->next_bd' is always true [knownConditionTrueFalse] fosfat-0.4.0-13-ged091bb/libfosfat/fosfat.c:1197:23: style: Condition 'dir_desc=dir_desc->next_bd' is always true [knownConditionTrueFalse] fosfat-0.4.0-13-ged091bb/libfosfat/fosfat.c:502:10: warning: Either the condition 'free_bd' is redundant or there is possible null pointer dereference: bd. [nullPointerRedundantCheck] fosfat-0.4.0-13-ged091bb/libfosfat/fosfat.c:515:9: note: Assuming that condition 'free_bd' is not redundant fosfat-0.4.0-13-ged091bb/libfosfat/fosfat.c:513:15: note: Assignment to 'free_bd=bd' fosfat-0.4.0-13-ged091bb/libfosfat/fosfat.c:502:10: note: Null pointer dereference fosfat-0.4.0-13-ged091bb/libfosfat/fosfat.c:514:10: warning: Either the condition 'free_bd' is redundant or there is possible null pointer dereference: bd. [nullPointerRedundantCheck] fosfat-0.4.0-13-ged091bb/libfosfat/fosfat.c:515:9: note: Assuming that condition 'free_bd' is not redundant fosfat-0.4.0-13-ged091bb/libfosfat/fosfat.c:513:13: note: free_bd is assigned 'bd' here. fosfat-0.4.0-13-ged091bb/libfosfat/fosfat.c:514:10: note: Null pointer dereference fosfat-0.4.0-13-ged091bb/libfosfat/fosfat.c:634:35: style: Parameter 'file' can be declared as pointer to const [constParameterPointer] fosfat-0.4.0-13-ged091bb/libfosfat/fosfat.c:646:35: style: Parameter 'file' can be declared as pointer to const [constParameterPointer] fosfat-0.4.0-13-ged091bb/libfosfat/fosfat.c:1250:9: style: Variable 'tmp' can be declared as pointer to const [constVariablePointer] fosfat-0.4.0-13-ged091bb/libfosfat/fosfat.c:1527:9: style: Variable 'start' can be declared as pointer to const [constVariablePointer] fosfat-0.4.0-13-ged091bb/libfosfat/fosfat.c:1935:63: warning: Found calculation inside sizeof(). [sizeofCalculation] fosfat-0.4.0-13-ged091bb/libfosgra/fosgra.c:220:3: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable p [valueFlowBailoutIncompleteVar] fosfat-0.4.0-13-ged091bb/libfosgra/fosgra.c:215:30: style: Parameter 'buffer' can be declared as pointer to const [constParameterPointer] fosfat-0.4.0-13-ged091bb/libfosgra/fosgra.c:66:12: style: struct member 'fosgra_image_h_s::res' is never used. [unusedStructMember] fosfat-0.4.0-13-ged091bb/libfosgra/fosgra.c:93:14: style: struct member 'Anonymous0::idx' is never used. [unusedStructMember] fosfat-0.4.0-13-ged091bb/libw32disk/w32disk.c:85:24: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable INVALID_HANDLE_VALUE [valueFlowBailoutIncompleteVar] fosfat-0.4.0-13-ged091bb/libw32disk/w32disk.c:125:22: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable INVALID_HANDLE_VALUE [valueFlowBailoutIncompleteVar] fosfat-0.4.0-13-ged091bb/libw32disk/w32disk.c:168:8: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable INVALID_HANDLE_VALUE [valueFlowBailoutIncompleteVar] fosfat-0.4.0-13-ged091bb/libw32disk/w32disk.c:193:7: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable INVALID_HANDLE_VALUE [valueFlowBailoutIncompleteVar] fosfat-0.4.0-13-ged091bb/libw32disk/w32disk.c:207:10: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable INVALID_HANDLE_VALUE [valueFlowBailoutIncompleteVar] fosfat-0.4.0-13-ged091bb/libw32disk/w32disk.c:217:7: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable INVALID_HANDLE_VALUE [valueFlowBailoutIncompleteVar] fosfat-0.4.0-13-ged091bb/libw32disk/w32disk.c:156:27: style:inconclusive: Function 'w32disk_new' argument 1 names different: declaration 'drive_index' definition 'drive_idx'. [funcArgNamesDifferent] fosfat-0.4.0-13-ged091bb/libw32disk/w32disk.h:33:38: note: Function 'w32disk_new' argument 1 names different: declaration 'drive_index' definition 'drive_idx'. fosfat-0.4.0-13-ged091bb/libw32disk/w32disk.c:156:27: note: Function 'w32disk_new' argument 1 names different: declaration 'drive_index' definition 'drive_idx'. fosfat-0.4.0-13-ged091bb/libw32disk/w32disk.c:212:40: style:inconclusive: Function 'w32disk_readsectors' argument 3 names different: declaration 'sector_index' definition 'sector_idx'. [funcArgNamesDifferent] fosfat-0.4.0-13-ged091bb/libw32disk/w32disk.h:38:44: note: Function 'w32disk_readsectors' argument 3 names different: declaration 'sector_index' definition 'sector_idx'. fosfat-0.4.0-13-ged091bb/libw32disk/w32disk.c:212:40: note: Function 'w32disk_readsectors' argument 3 names different: declaration 'sector_index' definition 'sector_idx'. fosfat-0.4.0-13-ged091bb/libw32disk/w32disk.c:212:59: style:inconclusive: Function 'w32disk_readsectors' argument 4 names different: declaration 'csectors' definition 'c_sectors'. [funcArgNamesDifferent] fosfat-0.4.0-13-ged091bb/libw32disk/w32disk.h:38:65: note: Function 'w32disk_readsectors' argument 4 names different: declaration 'csectors' definition 'c_sectors'. fosfat-0.4.0-13-ged091bb/libw32disk/w32disk.c:212:59: note: Function 'w32disk_readsectors' argument 4 names different: declaration 'csectors' definition 'c_sectors'. fosfat-0.4.0-13-ged091bb/libw32disk/w32disk.c:202:27: style: Parameter 'disk' can be declared as pointer to const [constParameterPointer] fosfat-0.4.0-13-ged091bb/tools/ascii.c:78:61: style:inconclusive: Function 'fos_sma2iso8859' argument 3 names different: declaration 'ret' definition 'newline'. [funcArgNamesDifferent] fosfat-0.4.0-13-ged091bb/tools/ascii.h:34:67: note: Function 'fos_sma2iso8859' argument 3 names different: declaration 'ret' definition 'newline'. fosfat-0.4.0-13-ged091bb/tools/ascii.c:78:61: note: Function 'fos_sma2iso8859' argument 3 names different: declaration 'ret' definition 'newline'. fosfat-0.4.0-13-ged091bb/tools/ascii.c:80:18: style: Variable 'i' is assigned a value that is never used. [unreadVariable] fosfat-0.4.0-13-ged091bb/tools/fosread.c:235:11: error: There is an unknown macro here somewhere. Configuration is required. If LIBFOSFAT_VERSION_STR is a macro then please configure it. [unknownMacro] fosfat-0.4.0-13-ged091bb/tools/fosrec.c:94:11: error: There is an unknown macro here somewhere. Configuration is required. If LIBFOSFAT_VERSION_STR is a macro then please configure it. [unknownMacro] fosfat-0.4.0-13-ged091bb/tools/smascii.c:61:14: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable stderr [valueFlowBailoutIncompleteVar] diff: head fosfat-0.4.0-13-ged091bb/libfosfat/fosfat.c:1114:18: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable stdout [valueFlowBailoutIncompleteVar] head fosfat-0.4.0-13-ged091bb/libw32disk/w32disk.c:125:22: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable INVALID_HANDLE_VALUE [valueFlowBailoutIncompleteVar] head fosfat-0.4.0-13-ged091bb/libw32disk/w32disk.c:168:8: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable INVALID_HANDLE_VALUE [valueFlowBailoutIncompleteVar] head fosfat-0.4.0-13-ged091bb/libw32disk/w32disk.c:193:7: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable INVALID_HANDLE_VALUE [valueFlowBailoutIncompleteVar] head fosfat-0.4.0-13-ged091bb/libw32disk/w32disk.c:207:10: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable INVALID_HANDLE_VALUE [valueFlowBailoutIncompleteVar] head fosfat-0.4.0-13-ged091bb/libw32disk/w32disk.c:217:7: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable INVALID_HANDLE_VALUE [valueFlowBailoutIncompleteVar] DONE