fix unit test for varFuncNullUB
This commit is contained in:
parent
de72ae9f45
commit
623e30d677
|
@ -6805,7 +6805,7 @@ private:
|
|||
void varFuncNullUB() { // #4482
|
||||
check("void a(...);\n"
|
||||
"void b() { a(NULL); }");
|
||||
ASSERT_EQUALS("[test.cpp:2]: (portability) Passing NULL to a function with variable number of arguments leads to undefined behaviour on some platforms.\n", errout.str());
|
||||
ASSERT_EQUALS("[test.cpp:2]: (portability) Passing NULL after the last typed argument to a variadic function leads to undefined behaviour.\n", errout.str());
|
||||
|
||||
check("void a(char *p, ...);\n"
|
||||
"void b() { a(NULL, 2); }");
|
||||
|
|
Loading…
Reference in New Issue