[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Octave-bug-tracker] [bug #37234] GUI crashes when stderr un-redirected

From: Dan Sebald
Subject: [Octave-bug-tracker] [bug #37234] GUI crashes when stderr un-redirected
Date: Sun, 14 Oct 2012 04:40:46 +0000
User-agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv: Gecko/20111108 Fedora/3.6.24-1.fc14 Firefox/3.6.24

Follow-up Comment #6, bug #37234 (project octave):

Comment #3 was a poor assumption on my part.  Getting rid of several bugs
didn't make this shutdown bug go away.

This bug isn't really related to stderr being un-redirected.  It's just that
when stderr is un-redirected, it is possible to see what the errors are.  If
the stderr is redirected to the GUI command line window there is no way for
one to see those error messages because the GUI is no longer visible.  (That
is why I say the GUI shouldn't be redirecting STDERR, but that causes other
problems with the pager.)

Anyway, I've attached a patch where I've simply gone through and cleaned up
the main_window destructor properly.  All these objects created dynamically
via "new" must be deleted.  Otherwise, especially in the case of "this" being
an argument of the constructor, problems can arise.  There could be orphaned
children still looking for "this" if main_window is cleaned up by the system
before the children are.  Basically, it is imperative in C++ OOP that dynamic
objects be cleaned up properly no matter the case.  Destructors often have
very important code.

I've tested out this simple cleanup and I no longer see any errors at
shutdown.  In fact, what happens is a slight delay, probably due to the system
and Qt properly destroying things.  I didn't extensively test this or look
elsewhere.  At this stage of my knowledge and what seems like several issues
I'm only going after wide swaths.

(file #26760)

Additional Item Attachment:

File name: octave-gui_main_window_cleanup-2012oct13.patch Size:4 KB


Reply to this item at:


  Message sent via/by Savannah

reply via email to

[Prev in Thread] Current Thread [Next in Thread]