From d0e6436a206bb3075b4f84f6da6e413e08751a0c Mon Sep 17 00:00:00 2001 From: adamdunkels Date: Tue, 9 Mar 2010 20:37:02 +0000 Subject: [PATCH] Don't call up the netstack if the transmission was deferred --- core/net/mac/contikimac.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/core/net/mac/contikimac.c b/core/net/mac/contikimac.c index a4dbacd9c..ce2001d36 100644 --- a/core/net/mac/contikimac.c +++ b/core/net/mac/contikimac.c @@ -28,7 +28,7 @@ * * This file is part of the Contiki operating system. * - * $Id: contikimac.c,v 1.9 2010/03/09 13:19:05 adamdunkels Exp $ + * $Id: contikimac.c,v 1.10 2010/03/09 20:37:02 adamdunkels Exp $ */ /** @@ -776,7 +776,9 @@ static void qsend_packet(mac_callback_t sent, void *ptr) { int ret = send_packet(sent, ptr); - mac_call_sent_callback(sent, ptr, ret, 1); + if(ret != MAC_TX_DEFERRED) { + mac_call_sent_callback(sent, ptr, ret, 1); + } } /*---------------------------------------------------------------------------*/ static void