mirror of
https://github.com/RIOT-OS/RIOT.git
synced 2024-12-29 04:50:03 +01:00
core: msg: don't wake up sender after receive if it's REPLY_BLOCKED
solves issue #100 If the sender is reply-blocked, waking it up after its message has been delivered is wrong. It needs to stay reply-blocked until the reply has been delivered.
This commit is contained in:
parent
3968ccffa8
commit
210a20b807
@ -269,8 +269,10 @@ static int _msg_receive(msg_t *m, int block)
|
||||
*m = *sender_msg;
|
||||
|
||||
/* remove sender from queue */
|
||||
sender->wait_data = NULL;
|
||||
sched_set_status(sender, STATUS_PENDING);
|
||||
if (sender->status != STATUS_REPLY_BLOCKED) {
|
||||
sender->wait_data = NULL;
|
||||
sched_set_status(sender, STATUS_PENDING);
|
||||
}
|
||||
|
||||
eINT();
|
||||
return 1;
|
||||
|
Loading…
Reference in New Issue
Block a user