mirror of
https://github.com/apache/nuttx.git
synced 2026-05-21 04:52:02 +08:00
sig_timedwait: Pending signal structure used after it has been releasd. From anonymous Bitbucket Issue 59.
This commit is contained in:
@@ -234,14 +234,14 @@ int sigtimedwait(FAR const sigset_t *set, FAR struct siginfo *info,
|
||||
memcpy(info, &sigpend->info, sizeof(struct siginfo));
|
||||
}
|
||||
|
||||
/* The return value is the number of the signal that awakened us */
|
||||
|
||||
ret = sigpend->info.si_signo;
|
||||
|
||||
/* Then dispose of the pending signal structure properly */
|
||||
|
||||
sig_releasependingsignal(sigpend);
|
||||
leave_critical_section(flags);
|
||||
|
||||
/* The return value is the number of the signal that awakened us */
|
||||
|
||||
ret = sigpend->info.si_signo;
|
||||
}
|
||||
|
||||
/* We will have to wait for a signal to be posted to this task. */
|
||||
|
||||
Reference in New Issue
Block a user