RIOT-OS/RIOT — pull request #2221 by Kijewski (2014-12-19 00:42:34+00:00)
Title:  core: msg_send_receive() corrupts the input 

`tcb_t::wait_data` is used both to send data and receive data.

This leads to the corruption of the paramter `m` in `msg_send_receive()`
if the target thread is not receive blocked and has no (or a full)
message queue.

This PR fixes the problem by writing the input message into a variable
on the stack first.