2025-05-06 11:15 ftp://ftp.de.debian.org/debian/pool/main/m/multitime/multitime_1.4.orig.tar.gz cppcheck-options: --library=posix --library=gnu --library=bsd --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 -j3 platform: Linux-6.8.0-1022-oracle-aarch64-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: ca3f092 (2025-05-06 12:26:46 +0200) count: 51 47 elapsed-time: 0.8 0.8 head-timing-info: old-timing-info: head results: multitime-1.4/multitime.c:80:17: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable stderr [valueFlowBailoutIncompleteVar] multitime-1.4/multitime.c:183:11: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable S_IRWXG [valueFlowBailoutIncompleteVar] multitime-1.4/multitime.c:550:17: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable stderr [valueFlowBailoutIncompleteVar] multitime-1.4/multitime.c:576:30: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable optarg [valueFlowBailoutIncompleteVar] multitime-1.4/format.c:51:17: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable stderr [valueFlowBailoutIncompleteVar] multitime-1.4/format.c:91:17: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable stderr [valueFlowBailoutIncompleteVar] multitime-1.4/format.c:130:66: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable ru_utime [valueFlowBailoutIncompleteVar] multitime-1.4/format.c:140:66: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable ru_stime [valueFlowBailoutIncompleteVar] multitime-1.4/format.c:159:1: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable ru_maxrss [valueFlowBailoutIncompleteVar] multitime-1.4/format.c:160:1: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable ru_minflt [valueFlowBailoutIncompleteVar] multitime-1.4/format.c:161:1: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable ru_majflt [valueFlowBailoutIncompleteVar] multitime-1.4/format.c:162:1: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable ru_nswap [valueFlowBailoutIncompleteVar] multitime-1.4/format.c:163:1: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable ru_inblock [valueFlowBailoutIncompleteVar] multitime-1.4/format.c:164:1: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable ru_oublock [valueFlowBailoutIncompleteVar] multitime-1.4/format.c:165:1: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable ru_msgsnd [valueFlowBailoutIncompleteVar] multitime-1.4/format.c:166:1: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable ru_msgrcv [valueFlowBailoutIncompleteVar] multitime-1.4/format.c:167:1: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable ru_nsignals [valueFlowBailoutIncompleteVar] multitime-1.4/format.c:168:1: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable ru_nvcsw [valueFlowBailoutIncompleteVar] multitime-1.4/format.c:169:1: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable ru_nivcsw [valueFlowBailoutIncompleteVar] multitime-1.4/format.c:188:43: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable ru_utime [valueFlowBailoutIncompleteVar] multitime-1.4/format.c:203:13: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable stderr [valueFlowBailoutIncompleteVar] multitime-1.4/format.c:44:30: style: Parameter 'cmd' can be declared as pointer to const [constParameterPointer] multitime-1.4/format.c:185:10: style: Variable 'cmd' can be declared as pointer to const [constVariablePointer] multitime-1.4/multitime.c:741:10: style: Obsolescent function 'usleep' called. It is recommended to use 'nanosleep' or 'setitimer' instead. [prohibitedusleepCalled] multitime-1.4/multitime.c:147:30: warning: If memory allocation fails, then there is a possible null pointer dereference: tv [nullPointerOutOfMemory] multitime-1.4/multitime.c:146:54: note: Assuming allocation function fails multitime-1.4/multitime.c:146:46: note: Assignment 'tv=cmd->timevals[runi]=malloc(sizeof(struct timeval))', assigned value is 0 multitime-1.4/multitime.c:147:30: note: Null pointer dereference multitime-1.4/multitime.c:213:26: warning:inconclusive: If memory allocation fails, then there is a possible null pointer dereference: buf [nullPointerOutOfMemory] multitime-1.4/multitime.c:211:23: note: Assuming allocation function fails multitime-1.4/multitime.c:211:23: note: Assignment 'buf=malloc(64*1024)', assigned value is 0 multitime-1.4/multitime.c:213:26: note: Null pointer dereference multitime-1.4/multitime.c:218:27: warning:inconclusive: If memory allocation fails, then there is a possible null pointer dereference: buf [nullPointerOutOfMemory] multitime-1.4/multitime.c:211:23: note: Assuming allocation function fails multitime-1.4/multitime.c:211:23: note: Assignment 'buf=malloc(64*1024)', assigned value is 0 multitime-1.4/multitime.c:214:29: note: Assuming condition is false multitime-1.4/multitime.c:218:27: note: Null pointer dereference multitime-1.4/multitime.c:248:17: warning: If memory allocation fails, then there is a possible null pointer dereference: rtn [nullPointerOutOfMemory] multitime-1.4/multitime.c:247:21: note: Assuming allocation function fails multitime-1.4/multitime.c:247:21: note: Assignment 'rtn=malloc(strlen(s)+1)', assigned value is 0 multitime-1.4/multitime.c:248:17: note: Null pointer dereference multitime-1.4/multitime.c:249:9: warning: If memory allocation fails, then there is a possible null pointer dereference: rtn [nullPointerOutOfMemory] multitime-1.4/multitime.c:247:21: note: Assuming allocation function fails multitime-1.4/multitime.c:247:21: note: Assignment 'rtn=malloc(strlen(s)+1)', assigned value is 0 multitime-1.4/multitime.c:249:9: note: Null pointer dereference multitime-1.4/multitime.c:307:15: warning: If memory allocation fails, then there is a possible null pointer dereference: bd [nullPointerOutOfMemory] multitime-1.4/multitime.c:306:22: note: Assuming allocation function fails multitime-1.4/multitime.c:306:22: note: Assignment 'bd=malloc(bfsz)', assigned value is 0 multitime-1.4/multitime.c:307:15: note: Null pointer dereference multitime-1.4/multitime.c:450:9: warning: If memory allocation fails, then there is a possible null pointer dereference: cmd [nullPointerOutOfMemory] multitime-1.4/multitime.c:449:26: note: Assuming allocation function fails multitime-1.4/multitime.c:449:26: note: Assignment 'cmd=malloc(sizeof(struct Cmd))', assigned value is 0 multitime-1.4/multitime.c:450:9: note: Null pointer dereference multitime-1.4/multitime.c:450:24: warning: If memory allocation fails, then there is a possible null pointer dereference: cmd [nullPointerOutOfMemory] multitime-1.4/multitime.c:449:26: note: Assuming allocation function fails multitime-1.4/multitime.c:449:26: note: Assignment 'cmd=malloc(sizeof(struct Cmd))', assigned value is 0 multitime-1.4/multitime.c:450:24: note: Null pointer dereference multitime-1.4/multitime.c:450:41: warning: If memory allocation fails, then there is a possible null pointer dereference: cmd [nullPointerOutOfMemory] multitime-1.4/multitime.c:449:26: note: Assuming allocation function fails multitime-1.4/multitime.c:449:26: note: Assignment 'cmd=malloc(sizeof(struct Cmd))', assigned value is 0 multitime-1.4/multitime.c:450:41: note: Null pointer dereference multitime-1.4/multitime.c:450:59: warning: If memory allocation fails, then there is a possible null pointer dereference: cmd [nullPointerOutOfMemory] multitime-1.4/multitime.c:449:26: note: Assuming allocation function fails multitime-1.4/multitime.c:449:26: note: Assignment 'cmd=malloc(sizeof(struct Cmd))', assigned value is 0 multitime-1.4/multitime.c:450:59: note: Null pointer dereference multitime-1.4/multitime.c:451:9: warning: If memory allocation fails, then there is a possible null pointer dereference: cmd [nullPointerOutOfMemory] multitime-1.4/multitime.c:449:26: note: Assuming allocation function fails multitime-1.4/multitime.c:449:26: note: Assignment 'cmd=malloc(sizeof(struct Cmd))', assigned value is 0 multitime-1.4/multitime.c:451:9: note: Null pointer dereference multitime-1.4/multitime.c:451:29: warning: If memory allocation fails, then there is a possible null pointer dereference: cmd [nullPointerOutOfMemory] multitime-1.4/multitime.c:449:26: note: Assuming allocation function fails multitime-1.4/multitime.c:449:26: note: Assignment 'cmd=malloc(sizeof(struct Cmd))', assigned value is 0 multitime-1.4/multitime.c:451:29: note: Null pointer dereference multitime-1.4/multitime.c:452:9: warning: If memory allocation fails, then there is a possible null pointer dereference: cmd [nullPointerOutOfMemory] multitime-1.4/multitime.c:449:26: note: Assuming allocation function fails multitime-1.4/multitime.c:449:26: note: Assignment 'cmd=malloc(sizeof(struct Cmd))', assigned value is 0 multitime-1.4/multitime.c:452:9: note: Null pointer dereference multitime-1.4/multitime.c:453:9: warning: If memory allocation fails, then there is a possible null pointer dereference: cmd [nullPointerOutOfMemory] multitime-1.4/multitime.c:449:26: note: Assuming allocation function fails multitime-1.4/multitime.c:449:26: note: Assignment 'cmd=malloc(sizeof(struct Cmd))', assigned value is 0 multitime-1.4/multitime.c:453:9: note: Null pointer dereference multitime-1.4/multitime.c:454:16: warning: If memory allocation fails, then there is a possible null pointer dereference: cmd [nullPointerOutOfMemory] multitime-1.4/multitime.c:449:26: note: Assuming allocation function fails multitime-1.4/multitime.c:449:26: note: Assignment 'cmd=malloc(sizeof(struct Cmd))', assigned value is 0 multitime-1.4/multitime.c:454:16: note: Null pointer dereference multitime-1.4/multitime.c:455:16: warning: If memory allocation fails, then there is a possible null pointer dereference: cmd [nullPointerOutOfMemory] multitime-1.4/multitime.c:449:26: note: Assuming allocation function fails multitime-1.4/multitime.c:449:26: note: Assignment 'cmd=malloc(sizeof(struct Cmd))', assigned value is 0 multitime-1.4/multitime.c:455:16: note: Null pointer dereference multitime-1.4/multitime.c:503:17: warning: If memory allocation fails, then there is a possible null pointer dereference: new_argv [nullPointerOutOfMemory] multitime-1.4/multitime.c:502:33: note: Assuming allocation function fails multitime-1.4/multitime.c:502:33: note: Assignment 'new_argv=malloc((argc-j+1)*sizeof(char*))', assigned value is 0 multitime-1.4/multitime.c:503:17: note: Null pointer dereference multitime-1.4/multitime.c:506:9: warning: If memory allocation fails, then there is a possible null pointer dereference: new_argv [nullPointerOutOfMemory] multitime-1.4/multitime.c:502:33: note: Assuming allocation function fails multitime-1.4/multitime.c:502:33: note: Assignment 'new_argv=malloc((argc-j+1)*sizeof(char*))', assigned value is 0 multitime-1.4/multitime.c:506:9: note: Null pointer dereference multitime-1.4/multitime.c:507:9: warning: If memory allocation fails, then there is a possible null pointer dereference: cmd [nullPointerOutOfMemory] multitime-1.4/multitime.c:449:26: note: Assuming allocation function fails multitime-1.4/multitime.c:449:26: note: Assignment 'cmd=malloc(sizeof(struct Cmd))', assigned value is 0 multitime-1.4/multitime.c:507:9: note: Null pointer dereference multitime-1.4/multitime.c:564:5: warning: If memory allocation fails, then there is a possible null pointer dereference: conf [nullPointerOutOfMemory] multitime-1.4/multitime.c:563:24: note: Assuming allocation function fails multitime-1.4/multitime.c:563:24: note: Assignment 'conf=malloc(sizeof(struct Conf))', assigned value is 0 multitime-1.4/multitime.c:564:5: note: Null pointer dereference multitime-1.4/multitime.c:565:5: warning: If memory allocation fails, then there is a possible null pointer dereference: conf [nullPointerOutOfMemory] multitime-1.4/multitime.c:563:24: note: Assuming allocation function fails multitime-1.4/multitime.c:563:24: note: Assignment 'conf=malloc(sizeof(struct Conf))', assigned value is 0 multitime-1.4/multitime.c:565:5: note: Null pointer dereference multitime-1.4/multitime.c:566:5: warning: If memory allocation fails, then there is a possible null pointer dereference: conf [nullPointerOutOfMemory] multitime-1.4/multitime.c:563:24: note: Assuming allocation function fails multitime-1.4/multitime.c:563:24: note: Assignment 'conf=malloc(sizeof(struct Conf))', assigned value is 0 multitime-1.4/multitime.c:566:5: note: Null pointer dereference multitime-1.4/multitime.c:567:5: warning: If memory allocation fails, then there is a possible null pointer dereference: conf [nullPointerOutOfMemory] multitime-1.4/multitime.c:563:24: note: Assuming allocation function fails multitime-1.4/multitime.c:563:24: note: Assignment 'conf=malloc(sizeof(struct Conf))', assigned value is 0 multitime-1.4/multitime.c:567:5: note: Null pointer dereference multitime-1.4/multitime.c:625:23: style: Local variable 'ep' shadows outer variable [shadowVariable] multitime-1.4/multitime.c:600:23: note: Shadowed declaration multitime-1.4/multitime.c:625:23: note: Shadow variable multitime-1.4/multitime.c:626:22: style: Local variable 'lval' shadows outer variable [shadowVariable] multitime-1.4/multitime.c:601:22: note: Shadowed declaration multitime-1.4/multitime.c:626:22: note: Shadow variable multitime-1.4/multitime.c:297:36: style: Parameter 'path' can be declared as pointer to const [constParameterPointer] multitime-1.4/multitime.c:547:32: style: Parameter 'msg' can be declared as pointer to const [constParameterPointer] diff: head multitime-1.4/multitime.c:450:24: warning: If memory allocation fails, then there is a possible null pointer dereference: cmd [nullPointerOutOfMemory] multitime-1.4/multitime.c:449:26: note: Assuming allocation function fails multitime-1.4/multitime.c:449:26: note: Assignment 'cmd=malloc(sizeof(struct Cmd))', assigned value is 0 multitime-1.4/multitime.c:450:24: note: Null pointer dereference head multitime-1.4/multitime.c:450:41: warning: If memory allocation fails, then there is a possible null pointer dereference: cmd [nullPointerOutOfMemory] multitime-1.4/multitime.c:449:26: note: Assuming allocation function fails multitime-1.4/multitime.c:449:26: note: Assignment 'cmd=malloc(sizeof(struct Cmd))', assigned value is 0 multitime-1.4/multitime.c:450:41: note: Null pointer dereference head multitime-1.4/multitime.c:450:59: warning: If memory allocation fails, then there is a possible null pointer dereference: cmd [nullPointerOutOfMemory] multitime-1.4/multitime.c:449:26: note: Assuming allocation function fails multitime-1.4/multitime.c:449:26: note: Assignment 'cmd=malloc(sizeof(struct Cmd))', assigned value is 0 multitime-1.4/multitime.c:450:59: note: Null pointer dereference head multitime-1.4/multitime.c:451:29: warning: If memory allocation fails, then there is a possible null pointer dereference: cmd [nullPointerOutOfMemory] multitime-1.4/multitime.c:449:26: note: Assuming allocation function fails multitime-1.4/multitime.c:449:26: note: Assignment 'cmd=malloc(sizeof(struct Cmd))', assigned value is 0 multitime-1.4/multitime.c:451:29: note: Null pointer dereference DONE