Skip to content

Commit

Permalink
Unlock sighand->lock on all codepaths of rt_sigtimedwait
Browse files Browse the repository at this point in the history
  • Loading branch information
tbodt committed May 3, 2023
1 parent c99cb7b commit a17fe7c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion kernel/signal.c
Original file line number Diff line number Diff line change
Expand Up @@ -681,14 +681,14 @@ int_t sys_rt_sigtimedwait(addr_t set_addr, addr_t info_addr, addr_t timeout_addr
break;
}
}
unlock(&current->sighand->lock);
if (!found)
return _EINTR;
struct siginfo_ info = sigqueue->info;
free(sigqueue);
if (info_addr != 0)
if (user_put(info_addr, info))
return _EFAULT;
unlock(&current->sighand->lock);
STRACE("done sigtimedwait = %d\n", info.sig);
return info.sig;
}
Expand Down

0 comments on commit a17fe7c

Please sign in to comment.