Mailing Lists: Apple Mailing Lists

Image of Mac OS face in stamp
 
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Crash in CFRunLoopSourceIsValid



pthread_exit() will release the thread's retain on the run loop object. But won't destroy it unless that's the last retain.

In this case, move this line up into the previous if:
CFRelease(gStandardRunLoopRef);
to:
if ((runLoop != nil) && (kRunLoopCancelled != runLoop)) {
CFRunLoopStop( runLoop);
CFRelease( runLoop);
}
to take advantage of the parameter checking already going on there.


Chris Kane
CoreFoundation, Apple


On May 13, 2004, at 5:44 AM, Dirk Musfeldt wrote:

Chris,

I tried to change the code, but I now got another crash. Is it possible that
the pthread_exit() implicitly destroys the CFRunLoop?


Date/Time: 2004-05-13 14:30:34 +0200
OS Version: 10.3.2 (Build 7D24)
Report Version: 2

Command: AlchemyTV DVR
Path: /Applications/AlchemyTV DVR/AlchemyTV
DVR.app/Contents/MacOS/AlchemyTV DVR
Version: AlchemyTV DVR version 2.1 (2.1)
PID: 868
Thread: 0

Exception: EXC_BAD_ACCESS (0x0001)
Codes: KERN_PROTECTION_FAILURE (0x0002) at 0x00000006

Thread 0 Crashed:
0 com.apple.CoreFoundation 0x90190c0c CFRelease + 0x24
1 Component 0x054054b0 0x53e2000 + 0x234b0
2 Component 0x053efae4 StopStandardRunLoop + 0x74
3 Component 0x053eb9c0
CloseIOService__FUiPUiPP12__CFMachPortPP17__CFRunLoopSourcePP17_opaque_ pthre
ad_t + 0xc0
[...]
_______________________________________________
darwin-development mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/darwin-development
Do not post admin requests to the list. They will be ignored.


References: 
 >Re: Crash in CFRunLoopSourceIsValid (From: Dirk Musfeldt <email@hidden>)



Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2007 Apple Inc. All rights reserved.