X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/819559b2ac7d2250097ce0b1d9d443164752be09..f822acceeee524d6e37fcbcaec3d795319c58d50:/src/xrc/xh_menu.cpp diff --git a/src/xrc/xh_menu.cpp b/src/xrc/xh_menu.cpp index f6cc1963f1..275c78aa62 100644 --- a/src/xrc/xh_menu.cpp +++ b/src/xrc/xh_menu.cpp @@ -148,7 +148,17 @@ wxMenuBarXmlHandler::wxMenuBarXmlHandler() : wxXmlResourceHandler() wxObject *wxMenuBarXmlHandler::DoCreateResource() { - wxMenuBar *menubar = new wxMenuBar(GetStyle()); + wxMenuBar *menubar = NULL; + + const int style = GetStyle(); + wxASSERT_MSG(!style || !m_instance, + "cannot use