diff mbox

[committed,obvious] Fix small leak in cfgloop.c

Message ID 4F099832.2080506@codesourcery.com
State New
Headers show

Commit Message

Chung-Lin Tang Jan. 8, 2012, 1:20 p.m. UTC
Hi, I noticed that cfgloop.c:cancel_loop() is missing a free of the bbs
array obtained from get_loop_body(). Committed attached patch as obvious.

Thanks,
Chung-Lin

2012-01-08  Chung-Lin Tang  <cltang@codesourcery.com>

        * cfgloop.c (cancel_loop): Add free() of bbs array.
diff mbox

Patch

Index: cfgloop.c
===================================================================
--- cfgloop.c	(revision 182989)
+++ cfgloop.c	(revision 182990)
@@ -1285,6 +1285,7 @@ 
   for (i = 0; i < loop->num_nodes; i++)
     bbs[i]->loop_father = outer;
 
+  free (bbs);
   delete_loop (loop);
 }