From da05833bb9dad82fd97a43dab14946479e42d8fb Mon Sep 17 00:00:00 2001 From: scipio Date: Wed, 3 Oct 2007 02:15:16 +0000 Subject: [PATCH] Found memory leak. --- tos/lib/net/ctp/CtpForwardingEngineP.nc | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/tos/lib/net/ctp/CtpForwardingEngineP.nc b/tos/lib/net/ctp/CtpForwardingEngineP.nc index e7cb53ce..55893c7c 100644 --- a/tos/lib/net/ctp/CtpForwardingEngineP.nc +++ b/tos/lib/net/ctp/CtpForwardingEngineP.nc @@ -440,6 +440,10 @@ implementation { if (call SentCache.lookup(qe->msg)) { call CollectionDebug.logEvent(NET_C_FE_DUPLICATE_CACHE_AT_SEND); call SendQueue.dequeue(); + if (call MessagePool.put(qe->msg) != SUCCESS) + call CollectionDebug.logEvent(NET_C_FE_PUT_MSGPOOL_ERR); + if (call QEntryPool.put(qe) != SUCCESS) + call CollectionDebug.logEvent(NET_C_FE_PUT_QEPOOL_ERR); post sendTask(); return; } -- 2.39.2