This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [patch #PR 26147/other] memory leak


> 	       You need a space here between free and the `('.

Ohh yes. Thanks Ben.

With this patch compiler has been bootstrapped ok on powerpc64-linux and
the test results show no new regressions.

Thanks,

Uttam

================================================================
2006-02-06  Uttam Pawar  <uttamp@us.ibm.com>

        PR other/26147
        * opts.c (common_handle_option): Free new_option pointer.
        * df-core.c (df_analyze): Free postorder pointer.

diff -urpN trunk.orig/gcc/df-core.c trunk/gcc/df-core.c
--- trunk.orig/gcc/df-core.c    2006-02-06 17:19:52.000000000 -0800
+++ trunk/gcc/df-core.c 2006-02-06 18:00:08.000000000 -0800
@@ -782,6 +782,7 @@ df_analyze (struct df *df)

   BITMAP_FREE (df->blocks_to_scan);
   df->blocks_to_scan = NULL;
+  free (postorder);
 }


diff -urpN trunk.orig/gcc/opts.c trunk/gcc/opts.c
--- trunk.orig/gcc/opts.c       2006-02-06 17:19:46.000000000 -0800
+++ trunk/gcc/opts.c    2006-02-06 23:16:10.000000000 -0800
@@ -790,6 +790,7 @@ common_handle_option (size_t scode, cons
                && kind == DK_ERROR)
              *(int *) cl_options[option_index].flag_var = 1;
          }
+        free (new_option);
       }
       break;


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]