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: [C++ PATCH] Fix C++ violation in g++.jason/init3.C (PR testsuite/63299)


On 09/19/2016 04:04 PM, Jakub Jelinek wrote:
Hi!

As valgrind reports, this testcase allocates the string with new [], but
deallocates with delete str.

Fixed thusly, regtested on x86_64-linux and i686-linux, ok for trunk?

2016-09-19  Maxim Ostapenko  <m.ostapenko@samsung.com>
	    Jakub Jelinek  <jakub@redhat.com>

	PR testsuite/63299
	* g++.old-deja/g++.jason/init3.C (My_string::~My_string): Use delete[]
	instead of delete.
OK.
jeff


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