tests: posix: Fix unchecked return coverity error
New test cases did not check return value of pthread_attr_init() Fixes #33809 Signed-off-by: David Leach <david.leach@nxp.com>
This commit is contained in:
parent
bd40cb48d9
commit
507a06fa82
|
@ -450,7 +450,8 @@ void test_posix_pthread_error_condition(void)
|
|||
EINVAL, "get datach state error");
|
||||
|
||||
/* Initialise thread attribute to ensure won't be return with init error */
|
||||
pthread_attr_init(&attr);
|
||||
zassert_false(pthread_attr_init(&attr),
|
||||
"Unable to create pthread object attr");
|
||||
zassert_false(pthread_attr_setschedpolicy(&attr, 0),
|
||||
"set scheduling policy error");
|
||||
zassert_false(pthread_attr_setschedpolicy(&attr, 1),
|
||||
|
|
Loading…
Reference in a new issue