posix.cfg: Added nullPointer tests for getop()

This commit is contained in:
orbitcowboy 2022-12-22 09:12:57 +01:00
parent 521f0ce720
commit 70ea3c2902
1 changed files with 9 additions and 0 deletions

View File

@ -36,6 +36,15 @@
#include <string.h>
#include <strings.h>
int nullPointer_getopt(int argc, char* const argv[], const char* optstring)
{
// cppcheck-suppress nullPointer
(void) getopt(argc, NULL, optstring);
// cppcheck-suppress nullPointer
(void) getopt(argc, argv, NULL);
return getopt(argc, argv, optstring);
}
int invalidFunctionArgStr_mq_send(mqd_t mqdes, const char *msg_ptr, size_t msg_len, unsigned msg_prio)
{
// No warning is expected for: