core: Fix msg_send_receive

Fixes #1935
Merge pull request #1937 from authmillenon/issue-1935

core: Fix msg_send_receive