X-Git-Url: http://nsz.repo.hu/git/?a=blobdiff_plain;f=src%2Fthread%2Fsynccall.c;h=ba2f258e8161962a63a4f53a82ff3be04b0669e7;hb=ebd8ef50d5012733d86ed4a6834ca6d776b069ae;hp=47d070b43e3984623be3dd99b744af66f42253a0;hpb=78a8ef47c4d92b7680c52a85f80a81e29da86bb9;p=musl diff --git a/src/thread/synccall.c b/src/thread/synccall.c index 47d070b4..ba2f258e 100644 --- a/src/thread/synccall.c +++ b/src/thread/synccall.c @@ -14,8 +14,8 @@ static struct chain { sem_t target_sem, caller_sem; } *volatile head; -static int synccall_lock[2]; -static int target_tid; +static volatile int synccall_lock[1]; +static volatile int target_tid; static void (*callback)(void *), *context; static volatile int dummy = 0; weak_alias(dummy, __block_new_threads); @@ -50,7 +50,7 @@ void __synccall(void (*func)(void *), void *ctx) int cs, i, r, pid, self;; DIR dir = {0}; struct dirent *de; - struct sigaction sa = { .sa_flags = 0, .sa_handler = handler }; + struct sigaction sa = { .sa_flags = SA_RESTART, .sa_handler = handler }; struct chain *cp, *next; struct timespec ts;