This is an automated email from the ASF dual-hosted git repository. xiaoxiang pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/nuttx-apps.git
commit 52c2a8909baaa49f3d4e1b5467a75970d04278ca Author: anpeiyun <[email protected]> AuthorDate: Sun Oct 26 11:29:33 2025 +0800 ostest/spinlock: Check the return value. This commit added checking for the return value. Signed-off-by: anpeiyun <[email protected]> --- testing/ostest/spinlock.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/testing/ostest/spinlock.c b/testing/ostest/spinlock.c index df691d7ca..7d66b64b6 100644 --- a/testing/ostest/spinlock.c +++ b/testing/ostest/spinlock.c @@ -149,7 +149,11 @@ static inline void run_test_thread( { param[i].pub = &pub; param[i].delta = 0; - pthread_create(&tid[i], NULL, thread_func, ¶m[i]); + ret = pthread_create(&tid[i], NULL, thread_func, ¶m[i]); + if (ret != 0) + { + ASSERT(false); + } } ret = pthread_barrier_wait(&pub.barrier);
