From: Maxim Ostapenko Date: Tue, 20 Sep 2016 15:19:14 +0000 (+0000) Subject: re PR testsuite/63299 (ASan reported alloc-dealloc-mismatch in g++.old-deja/g++.jason... X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=f5bd4ad831ce28b148a216c49be675127c1b947c;p=gcc.git re PR testsuite/63299 (ASan reported alloc-dealloc-mismatch in g++.old-deja/g++.jason/init3.C) PR testsuite/63299 * g++.old-deja/g++.jason/init3.C (My_string::~My_string): Use delete[] instead of delete. Co-Authored-By: Jakub Jelinek From-SVN: r240268 --- diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog index a15c601e33f..d515fdf5bcf 100644 --- a/gcc/testsuite/ChangeLog +++ b/gcc/testsuite/ChangeLog @@ -1,3 +1,10 @@ +2016-09-20 Maxim Ostapenko + Jakub Jelinek + + PR testsuite/63299 + * g++.old-deja/g++.jason/init3.C (My_string::~My_string): Use delete[] + instead of delete. + 2016-09-20 Jakub Jelinek PR c++/77626 diff --git a/gcc/testsuite/g++.old-deja/g++.jason/init3.C b/gcc/testsuite/g++.old-deja/g++.jason/init3.C index 38e0e61d325..92a7f5b89e3 100644 --- a/gcc/testsuite/g++.old-deja/g++.jason/init3.C +++ b/gcc/testsuite/g++.old-deja/g++.jason/init3.C @@ -10,7 +10,7 @@ class My_string { public: My_string(const char* string); My_string(const My_string &); - ~My_string() { delete str; } + ~My_string() { delete [] str; } char* char_p() { return str; } };