2025-07-10 11:22 ftp://ftp.de.debian.org/debian/pool/main/o/ocaml-mad/ocaml-mad_0.5.3.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 14.2.0-4ubuntu2~24.04) 14.2.0 cppcheck: head 2.17.0 head-info: 8f3d36a (2025-07-08 11:07:56 +0200) count: 25 25 elapsed-time: 0.1 0.3 head-timing-info: old-timing-info: head results: savonet-ocaml-mad-97c093f/src/mad_stubs.c:105:21: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable MAD_F_FRACBITS [valueFlowBailoutIncompleteVar] savonet-ocaml-mad-97c093f/src/mad_stubs.c:170:14: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable block [valueFlowBailoutIncompleteVar] savonet-ocaml-mad-97c093f/src/mad_stubs.c:230:14: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable block [valueFlowBailoutIncompleteVar] savonet-ocaml-mad-97c093f/src/mad_stubs.c:252:51: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable errno [valueFlowBailoutIncompleteVar] savonet-ocaml-mad-97c093f/src/mad_stubs.c:266:50: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable Val_unit [valueFlowBailoutIncompleteVar] savonet-ocaml-mad-97c093f/src/mad_stubs.c:342:56: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable MAD_ERROR_BUFLEN [valueFlowBailoutIncompleteVar] savonet-ocaml-mad-97c093f/src/mad_stubs.c:484:29: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable MAD_ERROR_BUFLEN [valueFlowBailoutIncompleteVar] savonet-ocaml-mad-97c093f/src/mad_stubs.c:519:14: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable ret [valueFlowBailoutIncompleteVar] savonet-ocaml-mad-97c093f/src/mad_stubs.c:565:14: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable ret [valueFlowBailoutIncompleteVar] savonet-ocaml-mad-97c093f/src/mad_stubs.c:592:14: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable ret [valueFlowBailoutIncompleteVar] savonet-ocaml-mad-97c093f/src/mad_stubs.c:630:3: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable ret [valueFlowBailoutIncompleteVar] savonet-ocaml-mad-97c093f/src/mad_stubs.c:665:31: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable MAD_ERROR_BUFLEN [valueFlowBailoutIncompleteVar] savonet-ocaml-mad-97c093f/src/mad_stubs.c:684:14: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable ans [valueFlowBailoutIncompleteVar] savonet-ocaml-mad-97c093f/src/mad_stubs.c:198:31: style:inconclusive: Boolean expression 'id3_header[0]==0x49' is used in bitwise operation. Did you mean '&&'? [bitwiseOnBoolean] savonet-ocaml-mad-97c093f/src/mad_stubs.c:198:57: style:inconclusive: Boolean expression 'id3_header[2]==0x33' is used in bitwise operation. Did you mean '&&'? [bitwiseOnBoolean] savonet-ocaml-mad-97c093f/src/mad_stubs.c:287:31: style:inconclusive: Boolean expression 'id3_header[0]==0x49' is used in bitwise operation. Did you mean '&&'? [bitwiseOnBoolean] savonet-ocaml-mad-97c093f/src/mad_stubs.c:287:57: style:inconclusive: Boolean expression 'id3_header[2]==0x33' is used in bitwise operation. Did you mean '&&'? [bitwiseOnBoolean] savonet-ocaml-mad-97c093f/src/mad_stubs.c:387:26: style: Condition 'read_size==0' is always true [knownConditionTrueFalse] savonet-ocaml-mad-97c093f/src/mad_stubs.c:385:21: note: Assuming that condition 'read_size>0' is not redundant savonet-ocaml-mad-97c093f/src/mad_stubs.c:387:26: note: Condition 'read_size==0' is always true savonet-ocaml-mad-97c093f/src/mad_stubs.c:145:3: warning: If memory allocation fails, then there is a possible null pointer dereference: mf [nullPointerOutOfMemory] savonet-ocaml-mad-97c093f/src/mad_stubs.c:140:14: note: Assuming allocation function fails savonet-ocaml-mad-97c093f/src/mad_stubs.c:140:14: note: Assignment 'mf=malloc(sizeof(struct madfile_t))', assigned value is 0 savonet-ocaml-mad-97c093f/src/mad_stubs.c:145:3: note: Null pointer dereference savonet-ocaml-mad-97c093f/src/mad_stubs.c:146:3: warning: If memory allocation fails, then there is a possible null pointer dereference: mf [nullPointerOutOfMemory] savonet-ocaml-mad-97c093f/src/mad_stubs.c:140:14: note: Assuming allocation function fails savonet-ocaml-mad-97c093f/src/mad_stubs.c:140:14: note: Assignment 'mf=malloc(sizeof(struct madfile_t))', assigned value is 0 savonet-ocaml-mad-97c093f/src/mad_stubs.c:146:3: note: Null pointer dereference savonet-ocaml-mad-97c093f/src/mad_stubs.c:147:3: warning: If memory allocation fails, then there is a possible null pointer dereference: mf [nullPointerOutOfMemory] savonet-ocaml-mad-97c093f/src/mad_stubs.c:140:14: note: Assuming allocation function fails savonet-ocaml-mad-97c093f/src/mad_stubs.c:140:14: note: Assignment 'mf=malloc(sizeof(struct madfile_t))', assigned value is 0 savonet-ocaml-mad-97c093f/src/mad_stubs.c:147:3: note: Null pointer dereference savonet-ocaml-mad-97c093f/src/mad_stubs.c:196:39: warning: If resource allocation fails, then there is a possible null pointer dereference: fd [nullPointerOutOfResources] savonet-ocaml-mad-97c093f/src/mad_stubs.c:184:19: note: Assuming allocation function fails savonet-ocaml-mad-97c093f/src/mad_stubs.c:184:19: note: Assignment 'fd=fopen(String_val(file),"rb")', assigned value is 0 savonet-ocaml-mad-97c093f/src/mad_stubs.c:196:39: note: Null pointer dereference savonet-ocaml-mad-97c093f/src/mad_stubs.c:116:3: style:inconclusive: Consecutive return, break, continue, goto or throw statements are unnecessary. [duplicateBreak] savonet-ocaml-mad-97c093f/src/mad_stubs.c:394:21: style: Checking if unsigned expression 'read_size' is less than zero. [unsignedLessThanZero] savonet-ocaml-mad-97c093f/src/mad_stubs.c:270:13: style: Variable 'id3_len' can be declared as pointer to const [constVariablePointer] diff: DONE