Fix memory leaks in tree-vect-data-refs.c
authorMartin Liska <mliska@suse.cz>
Thu, 10 Dec 2015 08:40:35 +0000 (09:40 +0100)
committerMartin Liska <marxin@gcc.gnu.org>
Thu, 10 Dec 2015 08:40:35 +0000 (08:40 +0000)
* tree-vect-data-refs.c: Free an overwritten dataref.

From-SVN: r231490

gcc/ChangeLog
gcc/tree-vect-data-refs.c

index 0bf6ebd74af18164aa6df8496733c88760e78934..e0c72edb875e8d3596f782b5b1049a3b3b94b53c 100644 (file)
@@ -1,3 +1,7 @@
+2015-12-10  Martin Liska  <mliska@suse.cz>
+
+       * tree-vect-data-refs.c: Free an overwritten dataref.
+
 2015-12-09  John David Anglin  <danglin@gcc.gnu.org>
 
        PR target/68729
index 8810af1bfcd4a90ae75aed732670d107b525f496..4c566c84766a6d4a3b201d10b52b2cbf2b958e45 100644 (file)
@@ -3847,6 +3847,7 @@ again:
              return false;
            }
 
+         free_data_ref (datarefs[i]);
          datarefs[i] = dr;
          STMT_VINFO_GATHER_SCATTER_P (stmt_info) = gatherscatter;
        }