std.cfg: Improved configuration of some <thread.h> (since C11) functions.
This commit is contained in:
parent
0a4e2abf01
commit
f23111d610
|
@ -8004,6 +8004,7 @@ initializer list (7) string& replace (const_iterator i1, const_iterator i2, init
|
|||
<returnValue type="void"/>
|
||||
<leak-ignore/>
|
||||
<arg nr="1" direction="in">
|
||||
<not-null/>
|
||||
<not-uninit/>
|
||||
<not-bool/>
|
||||
</arg>
|
||||
|
|
|
@ -23,6 +23,7 @@
|
|||
#include <time.h>
|
||||
#include <stdbool.h>
|
||||
#include <stdint.h>
|
||||
#include <threads.h>
|
||||
#include <inttypes.h>
|
||||
#include <float.h>
|
||||
|
||||
|
@ -4363,6 +4364,15 @@ void nullPointer_system(char *c)
|
|||
(void)system(c);
|
||||
}
|
||||
|
||||
int nullPointer_mtx_timedlock( mtx_t *restrict mutex, const struct timespec *restrict time_point )
|
||||
{
|
||||
// cppcheck-suppress nullPointer
|
||||
(void) mtx_timedlock(NULL, time_point);
|
||||
// cppcheck-suppress nullPointer
|
||||
(void) mtx_timedlock(mutex, NULL);
|
||||
return mtx_timedlock(mutex, time_point);
|
||||
}
|
||||
|
||||
void uninitvar_zonetime(void)
|
||||
{
|
||||
time_t *tp;
|
||||
|
|
|
@ -26,6 +26,7 @@
|
|||
#include <cwchar>
|
||||
#include <fstream>
|
||||
#include <functional>
|
||||
#include <threads.h>
|
||||
#include <iomanip>
|
||||
#include <ios>
|
||||
#include <iostream>
|
||||
|
@ -3660,6 +3661,36 @@ void uninitvar_system(void)
|
|||
(void)std::system(c);
|
||||
}
|
||||
|
||||
void nullPointer_mtx_destroy( mtx_t *mutex )
|
||||
{
|
||||
// cppcheck-suppress nullPointer
|
||||
mtx_destroy(nullptr);
|
||||
mtx_destroy(mutex);
|
||||
}
|
||||
|
||||
void nullPointer_mtx_lock( mtx_t *mutex )
|
||||
{
|
||||
// cppcheck-suppress nullPointer
|
||||
mtx_lock(nullptr);
|
||||
mtx_lock(mutex);
|
||||
}
|
||||
|
||||
void nullPointer_mtx_trylock( mtx_t *mutex )
|
||||
{
|
||||
// cppcheck-suppress nullPointer
|
||||
mtx_trylock(nullptr);
|
||||
mtx_trylock(mutex);
|
||||
}
|
||||
|
||||
int nullPointer_mtx_timedlock( mtx_t *mutex, const struct timespec *time_point )
|
||||
{
|
||||
// cppcheck-suppress nullPointer
|
||||
(void) mtx_timedlock(nullptr, time_point);
|
||||
// cppcheck-suppress nullPointer
|
||||
(void) mtx_timedlock(mutex, nullptr);
|
||||
return mtx_timedlock(mutex, time_point);
|
||||
}
|
||||
|
||||
void nullPointer_system(char *c)
|
||||
{
|
||||
// If a null pointer is given, command processor is checked for existence
|
||||
|
|
Loading…
Reference in New Issue