N
Nick Keighley
Yes I know, you're not supposed to do that.
new char a[10]
do_something();
delete a;
now is that a memory leak or is it that the DTORs aren't invoked or is
it simply Undefined Behaviour.
I ask because it's an existing code base and I wondered how urgent it
was that it got fixed?
This is obviously a memory leak
new std::string strs[10];
delete strs;
new char a[10]
do_something();
delete a;
now is that a memory leak or is it that the DTORs aren't invoked or is
it simply Undefined Behaviour.
I ask because it's an existing code base and I wondered how urgent it
was that it got fixed?
This is obviously a memory leak
new std::string strs[10];
delete strs;