From 4295d028ec37e3d5545aaeea32478e08ad11d438 Mon Sep 17 00:00:00 2001 From: daniel-k Date: Mon, 12 Oct 2015 20:20:27 +0200 Subject: [PATCH] core/msg_reply: only assert target tcb, no error handling --- core/msg.c | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/core/msg.c b/core/msg.c index 45999420b7..8828b4ec84 100644 --- a/core/msg.c +++ b/core/msg.c @@ -228,13 +228,7 @@ int msg_reply(msg_t *m, msg_t *reply) unsigned state = disableIRQ(); tcb_t *target = (tcb_t*) sched_threads[m->sender_pid]; - - if (!target) { - DEBUG("msg_reply(): %" PRIkernel_pid ": Target \"%" PRIkernel_pid - "\" not existing...dropping msg!\n", sched_active_thread->pid, - m->sender_pid); - return -1; - } + assert(target != NULL); if (target->status != STATUS_REPLY_BLOCKED) { DEBUG("msg_reply(): %" PRIkernel_pid ": Target \"%" PRIkernel_pid