discuss-gnustep
[Top][All Lists]
Advanced

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

Re: Crashing in _Block_release


From: David Chisnall
Subject: Re: Crashing in _Block_release
Date: Wed, 29 Feb 2012 22:32:38 +0000

Please can you send me a test case?

David

On 29 Feb 2012, at 22:30, Jens Alfke wrote:

> I’m hitting a nasty crash that I can reproduce by running a single one of my 
> unit tests. It’s impossible to “bt” at the point of the crash, but I was able 
> to narrow it down to a _Block_release call made while draining an autorelease 
> pool. Now I’m stuck, though — after the crash has occurred, the PC is bogus 
> (0x0019) and the stack is smashed, so I can’t tell what happened.
> 
> Any ideas, or suggestions how to debug further? The block does appear to be a 
> valid object before the call (see below).
> 
> One possible clue: gdb says the function is at blocks_runtime.m:283, but my 
> copy of blocks_runtime.m only has 261 lines and _Block_release is at line 
> 234. I hope there’s not a version mismatch between Base and the libobjc2 
> runtime; what would be the best way to tell if there is?
> 
> —Jens
> 
> Breakpoint 1, _Block_release (src=<optimized out>, src=<optimized out>) at 
> blocks_runtime.m:283
> 283   {
> (gdb) bt
> #0  _Block_release (src=<optimized out>, src=<optimized out>) at 
> blocks_runtime.m:283
> #1  0x0024578c in -[GSBlock release] (self=0x81b7330, _cmd=0x721ea8) at 
> GSBlocks.m:81
> #2  0x002c7d01 in -[NSAutoreleasePool emptyPool] (self=0x8106f64, 
> _cmd=0x721e90) at NSAutoreleasePool.m:658
> #3  0x002c7825 in -[NSAutoreleasePool dealloc] (self=0x8106f64, 
> _cmd=0x721ee8) at NSAutoreleasePool.m:538
> #4  0x002c76a0 in -[NSAutoreleasePool drain] (self=0x8106f64, _cmd=0x8ff678) 
> at NSAutoreleasePool.m:519
> #5  0x008b2841 in RunTestCase (test=0x8fec40) at vendor/MYUtilities/Test.m:69
> #6  0x008b21f5 in RunTestCaseNamed (name=0xbffff439 "MYAfterDelay") at 
> vendor/MYUtilities/Test.m:83
> #7  0x008b2396 in RunTestCases (argc=2, argv=0xbffff2a4) at 
> vendor/MYUtilities/Test.m:114
> #8  0x08048752 in main (argc=2, argv=0xbffff2a4) at 
> Demo-Mac/EmptyGNUstepApp.m:29
> (gdb) print [0x81b7330 retainCount]
> $2 = 34
> (gdb) finish
> Run till exit from #0  _Block_release (src=<optimized out>, src=<optimized 
> out>) at blocks_runtime.m:283
> 
> Program received signal SIGSEGV, Segmentation fault.
> 0x00000019 in ?? ()
> (gdb) bt
> #0  0x00000019 in ?? ()
> Backtrace stopped: Not enough registers or memory available to unwind further
> (gdb) 
> 
> 
> _______________________________________________
> Discuss-gnustep mailing list
> address@hidden
> https://lists.gnu.org/mailman/listinfo/discuss-gnustep


-- Sent from my STANTEC-ZEBRA




reply via email to

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