Skip to content

Commit 10fa6f8

Browse files
committed
wolfcrypt/src/async.c: check and report retval from wc_AsyncThreadCreate_ex in exit_fail section.
1 parent 1a1f6ab commit 10fa6f8

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

wolfcrypt/src/async.c

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -952,7 +952,9 @@ int wc_AsyncThreadCreate_ex(pthread_t *thread,
952952
exit_fail:
953953

954954
fprintf(stderr, "AsyncThreadCreate error: %d\n", status);
955-
(void)pthread_attr_destroy(&attr);
955+
status = pthread_attr_destroy(&attr);
956+
if (status != 0)
957+
fprintf(stderr, "AsyncThreadCreate cleanup error: %d\n", status);
956958
return ASYNC_OP_E;
957959
}
958960

0 commit comments

Comments
 (0)