incubator-ooo-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
Subject [Bug 120095] openoffice crashes when the first time to exit quickstarter after it being enabled
Date Sun, 01 Jul 2012 14:39:17 GMT

--- Comment #8 from Ariel Constenla-Haile <> ---
Committed in trunk under revision 1355915

Applied the attached patch with a few modifications to prevent a leak when
posting the user event fails.
ToDo: I took the idea of the asynchronous desktop termination from the way how
UI elements' controllers call the dispatch (the scenario is almost the same as
in this crash report, just search "Application::PostUserEvent" in svtools and
framework), most code on these modules should fix the leak, see for example 
framework::RecentFilesMenuController::executeEntry( sal_Int32 nIndex )

if ( )
    // Call dispatch asychronously as we can be destroyed while dispatch is
    // executed. VCL is not able to survive this as it wants to call listeners
    // after select!!!
    LoadRecentFile* pLoadRecentFile = new LoadRecentFile;
    pLoadRecentFile->xDispatch  = xDispatch;
    pLoadRecentFile->aTargetURL = aTargetURL;
    pLoadRecentFile->aArgSeq    = aArgsList;

    if(::comphelper::UiEventsLogger::isEnabled()) //#i88653#
m_xFrame, aTargetURL, aArgsList);

    Application::PostUserEvent( STATIC_LINK(0, RecentFilesMenuController,
ExecuteHdl_Impl), pLoadRecentFile );

to fix the leak:

if (!Application::PostUserEvent( STATIC_LINK(0, RecentFilesMenuController,
ExecuteHdl_Impl), pLoadRecentFile ))
delete  pLoadRecentFile;

You are receiving this mail because:
You are the assignee for the bug.

View raw message