fixed some memory leak in the test
authorGengbin Zheng <gzheng@illinois.edu>
Wed, 17 Aug 2011 20:37:04 +0000 (13:37 -0700)
committerGengbin Zheng <gzheng@illinois.edu>
Wed, 17 Aug 2011 20:37:04 +0000 (13:37 -0700)
tests/converse/megacon/deadlock.c

index 5c8bcb7d5f6458bac17c0983690a5891dcc95cf1..d5524658c03fa9429853fedfb89e60d8a092d773 100644 (file)
@@ -20,6 +20,7 @@ void deadlock_inc(incmsg m)
   if (CpvAccess(deadlock_count)==0) {
     Cpm_megacon_ack(CpmSend(0));
   }
+  CmiFree(m);
 }
 
 void deadlock_cram(char *msg)
@@ -33,6 +34,7 @@ void deadlock_cram(char *msg)
   } 
   m.n = -count;
   CmiSyncSend(1-CmiMyPe(), sizeof(m), &m);
+  CmiFree(msg);
 }
 
 void deadlock_init()