Деян Хаджиев
2014-06-03 13:29:51 UTC
Hi,
I've been struggling with a problem with wxWidgets 3.1 on OSX-Cocoa for
several days, and couldn't find where's the origin of the problem (I'm
still searching though). The problem is that the application crashes even
before it's OnInit() function is called. I have an DECLARE_APP(MyApp) and
IMPLEMENT_APP_NO_MAIN(MyApp) macros in the compilation unit. This is a copy
of the stack frames:
Program received signal EXC_BAD_ACCESS, Could not access memory.
Reason: KERN_INVALID_ADDRESS at address: 0x0000000000000000
0x0000000101051aa0 in -[wxNSAppController applicationWillFinishLaunching:]
(self=0x10500b8c0, _cmd=0x7fff88988588, application=0x102543b80) at
../src/osx/cocoa/utils.mm:67
67 wxTheApp->OSXOnWillFinishLaunching();
(gdb) bt
#0 0x0000000101051aa0 in -[wxNSAppController
applicationWillFinishLaunching:] (self=0x10500b8c0, _cmd=0x7fff88988588,
application=0x102543b80) at ../src/osx/cocoa/utils.mm:67
#1 0x00007fff81564ad5 in _nsnote_callback ()
#2 0x00007fff88d36fd0 in __CFXNotificationPost ()
#3 0x00007fff88d23548 in _CFXNotificationPostNotification ()
#4 0x00007fff8155ba36 in -[NSNotificationCenter
postNotificationName:object:userInfo:] ()
#5 0x00007fff81979901 in -[NSApplication finishLaunching] ()
#6 0x00007fff81979554 in -[NSApplication run] ()
#7 0x00000001010523b4 in wxApp::CallOnInit (this=0x10253f700) at
../src/osx/cocoa/utils.mm:448
#8 0x00000001002ed5b2 in wxEntry () at ../src/common/init.cpp:479
It seems that wxTheApp is NULL, but I could not check it in the debugger
(no symbol "wxTheApp" in current context, although my build is with
--enable-debug). I could not recreate the problem with the minimal sample.
I don't know if this is relevant, but wxWidgets library is statically
linked to a shared library in my application. I thought that this may be of
some importance.
TIA for any help.
Best regards
Deyan Hadzhiev
I've been struggling with a problem with wxWidgets 3.1 on OSX-Cocoa for
several days, and couldn't find where's the origin of the problem (I'm
still searching though). The problem is that the application crashes even
before it's OnInit() function is called. I have an DECLARE_APP(MyApp) and
IMPLEMENT_APP_NO_MAIN(MyApp) macros in the compilation unit. This is a copy
of the stack frames:
Program received signal EXC_BAD_ACCESS, Could not access memory.
Reason: KERN_INVALID_ADDRESS at address: 0x0000000000000000
0x0000000101051aa0 in -[wxNSAppController applicationWillFinishLaunching:]
(self=0x10500b8c0, _cmd=0x7fff88988588, application=0x102543b80) at
../src/osx/cocoa/utils.mm:67
67 wxTheApp->OSXOnWillFinishLaunching();
(gdb) bt
#0 0x0000000101051aa0 in -[wxNSAppController
applicationWillFinishLaunching:] (self=0x10500b8c0, _cmd=0x7fff88988588,
application=0x102543b80) at ../src/osx/cocoa/utils.mm:67
#1 0x00007fff81564ad5 in _nsnote_callback ()
#2 0x00007fff88d36fd0 in __CFXNotificationPost ()
#3 0x00007fff88d23548 in _CFXNotificationPostNotification ()
#4 0x00007fff8155ba36 in -[NSNotificationCenter
postNotificationName:object:userInfo:] ()
#5 0x00007fff81979901 in -[NSApplication finishLaunching] ()
#6 0x00007fff81979554 in -[NSApplication run] ()
#7 0x00000001010523b4 in wxApp::CallOnInit (this=0x10253f700) at
../src/osx/cocoa/utils.mm:448
#8 0x00000001002ed5b2 in wxEntry () at ../src/common/init.cpp:479
It seems that wxTheApp is NULL, but I could not check it in the debugger
(no symbol "wxTheApp" in current context, although my build is with
--enable-debug). I could not recreate the problem with the minimal sample.
I don't know if this is relevant, but wxWidgets library is statically
linked to a shared library in my application. I thought that this may be of
some importance.
TIA for any help.
Best regards
Deyan Hadzhiev
--
Please read http://www.wxwidgets.org/support/mlhowto.htm before posting.
To unsubscribe, send email to wx-users+***@googlegroups.com
or visit http://groups.google.com/group/wx-users
Please read http://www.wxwidgets.org/support/mlhowto.htm before posting.
To unsubscribe, send email to wx-users+***@googlegroups.com
or visit http://groups.google.com/group/wx-users