Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 6 additions & 1 deletion test/lib/native/testlib_threads.h
Original file line number Diff line number Diff line change
Expand Up @@ -81,10 +81,15 @@ void run_in_new_thread_and_join(PROCEDURE proc, void* context) {
}
#else
pthread_t thread;
int result = pthread_create(&thread, NULL, procedure, &helper);
pthread_attr_t attr;
pthread_attr_init(&attr);
size_t stack_size = 0x100000;
pthread_attr_setstacksize(&attr, stack_size);
int result = pthread_create(&thread, &attr, procedure, &helper);
if (result != 0) {
fatal("failed to create thread", result);
}
pthread_attr_destroy(&attr);
result = pthread_join(thread, NULL);
if (result != 0) {
fatal("failed to join thread", result);
Expand Down