diff --git a/cfg/posix.cfg b/cfg/posix.cfg index f07f8fe8b..7cde306a3 100644 --- a/cfg/posix.cfg +++ b/cfg/posix.cfg @@ -2197,7 +2197,7 @@ The function 'mktemp' is considered to be dangerous due to race conditions and s - + @@ -2209,7 +2209,7 @@ The function 'mktemp' is considered to be dangerous due to race conditions and s - + @@ -2221,7 +2221,7 @@ The function 'mktemp' is considered to be dangerous due to race conditions and s - + diff --git a/test/cfg/posix.c b/test/cfg/posix.c index 3da495953..0621e9836 100644 --- a/test/cfg/posix.c +++ b/test/cfg/posix.c @@ -330,6 +330,13 @@ double nullPointer_erand48(unsigned short xsubi[3]) return erand48(xsubi); } +struct non_const_parameter_erand48_struct { unsigned short xsubi[3]; }; +// No warning is expected that dat can be const +double non_const_parameter_erand48(struct non_const_parameter_erand48_struct *dat) +{ + return erand48(dat->xsubi); +} + unsigned short *nullPointer_seed48(unsigned short seed16v[3]) { // cppcheck-suppress nullPointer