1
0
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:
Kaspar Schleiser 2014-01-25 15:42:13 +01:00
parent 3968ccffa8
commit 210a20b807

View File

@ -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;