Merged in sliedl/nuttx (pull request #700)
sched/mqueue/mq_notify.c: Fix - only part of struct copied to internal structure As source adress the adress of the struct member sigev_value was used, and it is not located the start of the struct. This leads to invalid data being copied to internal structure. Both source and destination should be of type struct sigevent* . Approved-by: GregoryN <gnutt@nuttx.org>
This commit is contained in:
parent
c14d97a921
commit
6fe770bb21
|
@ -152,7 +152,7 @@ int mq_notify(mqd_t mqdes, FAR const struct sigevent *notification)
|
|||
|
||||
/* Yes... Assign it to the current task. */
|
||||
|
||||
memcpy(&msgq->ntevent, ¬ification->sigev_value,
|
||||
memcpy(&msgq->ntevent, notification,
|
||||
sizeof(struct sigevent));
|
||||
|
||||
msgq->ntpid = rtcb->pid;
|
||||
|
|
Loading…
Reference in New Issue