Developer forums (C::B DEVELOPMENT STRICTLY!) > Development

Crash on close if ANY window undocked?!

<< < (2/4) > >>

thomas:
The good news: I fixed the problem in the debugger plugin.
Naively speaking, is as easy as that:

--- Code: ----    if (m_pExamineMemoryDlg)
+    if (!appShutDown && m_pExamineMemoryDlg)
    {
        CodeBlocksDockEvent evt(cbEVT_REMOVE_DOCK_WINDOW);
        evt.pWindow = m_pExamineMemoryDlg;
        Manager::Get()->GetAppWindow()->ProcessEvent(evt);
        m_pExamineMemoryDlg->Destroy();
    }
--- End code ---

The bad news: This is a symptom, not the cause. As the debugger plugin works fine, the TODO plugin will crash for the same reason, and as that one is fixed, another one...

The crash happens inside MainFrame::OnApplicationClose when Manager::Shutdown() is called (during OnRelease of certain plugins).

The debugger plugin, the todo plugin, and some others post cbEVT_REMOVE_DOCK_WINDOW events during their shutdown functions.

This should actually be fine, but for some reason it is not OK if a dock window is undocked. Apparently, these events are only processed after the main frame has been destroyed...

MortenMacFly:
I was away until today so I read the new just by now. Sorry for the delayed answer.
It is valuable information at least in the way that I didn't get that far... ;-)
Anyway... I agree: This is strange. Didn't mandrav know the author of the wxAUI plugin? Maybe he has another hint. Because if this error is really something related to wxAUI (which still could be if I understand what you've written). He should receive a lot of support requests because of that. Also interesting to know is if this also happens if one uses wxWidgets in another version - e.g. 2.6.1 or 2.6.3 (RC somehwat). This would show up if it's a problem with wxWidets itself... Anyone out there not using version 2.6.2???
With regards, Morten.

MortenMacFly:

--- Quote from: MortenMacFly on March 12, 2006, 07:04:34 pm ---Anyone out there not using version 2.6.2???

--- End quote ---
Thomas, I've got good news!
I've compiled wxWidgets version 2.6.1 and then re-build Code::Blocks from scratch using this version of wxWidgets (2.6.1). And guess what? You CAN undock and close C::B without any crashes. So I guess it's really a bug with wxWidgets. Maybe C::B should stick with wxWidgets 2.6.1? I remember other issues that maybe releated to 2.6.2, too.
Now, why is this good news? Because it may be an issue that'll be fixed in 2.6.3... ;-)
With regards, Morten.

MortenMacFly:

--- Quote from: MortenMacFly on March 16, 2006, 07:40:13 pm ---Anyone out there not using version 2.6.2???

--- End quote ---
Well, by now I've compiled wxWidgets 2.6.3-RC1. And guess what: It works there, too. I would say that this is proof enough to say that this issue is wxWidgets 2.6.2 related. Furthermore I suggest not putting too much effort into this anymore - sooner or later C::B will work with wxWidgets 2.6.3 (release) anyway...
With regards, Morten.

MortenMacFly:
This will be my last post to this topic, but it has to be said:
By now I've completely removed all *.o;*.a;*.gch files and removed the "devel" and "output" directory completely. Then I made a rebuild using wxWidgets 2.6.2 (that's exactly the same way I did it with the other versions of wxWidgets) and now it works. The bug suddenly has "disappeard" allthough I'm really doing the same: Undocking a debug-related window outside C::B. Now that's absolutely strange and to be honest: I have no glue what happens here. At least you (Thomas) experienced the same issue so I'm not alone. ;-)
Anyway: Anybody else experiencing such strange crashes should maybe follow my instructions before complaining.
With regards, Morten.

Navigation

[0] Message Index

[#] Next page

[*] Previous page

Go to full version