[Interest] Create the main widget on heap in main()

Etienne Sandré-Chardonnal etienne.sandre at m4x.org
Sat Jan 11 13:30:15 CET 2014


2014/1/11 Constantin Makshin <cmakshin at gmail.com>

> True, but why would one need a parented object in main()? :-)
>

True, but an object that should be deleted at the last line of main but is
not by mistake is a non-leak :)
The process heap is deleted anyway...

I've seen already several crashes due to QObjects on stack and double
deletions, I just want to point this out...

Cheers,

Etienne
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.qt-project.org/pipermail/interest/attachments/20140111/71c92e18/attachment.html>


More information about the Interest mailing list