Tk Source Code

View Ticket
Login
Ticket UUID: dd5e4b73e0bfdde045f546dc559e2cbca22ea302
Title: Crash in Tk
Type: Bug Version: 8.6.2
Submitter: hypnotoad Created on: 2014-09-04 19:02:38
Subsystem: 66. Aqua Window Operations Assigned To: nobody
Priority: 5 Medium Severity: Critical
Status: Closed Last Modified: 2017-11-27 14:59:04
Resolution: Out of Date Closed By: hypnotoad
    Closed on: 2017-11-27 14:59:04
Description:
At random my application crashes with the following stack trace:

My guess is that it's at least tangentially related to the OTHER Freeing/Garbage Collection we sorted out last week.

Process:         irmsde [9134]
Path:            /Users/USER/*/irmsde
Identifier:      irmsde
Version:         0
Code Type:       X86-64 (Native)
Parent Process:  bash [95738]
Responsible:     Terminal [75111]
User ID:         501

Date/Time:       2014-09-04 14:52:05.746 -0400
OS Version:      Mac OS X 10.9.4 (13E28)
Report Version:  11
Anonymous UUID:  EAB60C7C-4834-FAFF-68F3-0BCB1A2842A1

Sleep/Wake UUID: 34114FA6-1C8C-46AB-9090-1B5AF783CEC5

Crashed Thread:  0  Dispatch queue: com.apple.main-thread

Exception Type:  EXC_BAD_ACCESS (SIGSEGV)
Exception Codes: EXC_I386_GPFLT

Thread 0 Crashed:: Dispatch queue: com.apple.main-thread
0   libobjc.A.dylib               	0x00007fff95a3a0e6 objc_release + 22
1   libobjc.A.dylib               	0x00007fff95a3965a (anonymous namespace)::AutoreleasePoolPage::pop(void*) + 502
2   com.apple.CoreFoundation      	0x00007fff97151932 _CFAutoreleasePoolPop + 50
3   com.apple.Foundation          	0x00007fff99aeae17 -[NSAutoreleasePool drain] + 147
4   irmsde                        	0x000000010bf82c73 -[TKApplication(TKNotify) nextEventMatchingMask:untilDate:inMode:dequeue:] + 264
5   irmsde                        	0x000000010bf82fc8 TkMacOSXEventsCheckProc + 255
6   irmsde                        	0x000000010be8327f Tcl_DoOneEvent + 314
7   irmsde                        	0x000000010be4a034 Tcl_VwaitObjCmd + 153
8   irmsde                        	0x000000010bdd6f8a TclNRRunCallbacks + 80
9   irmsde                        	0x000000010bdd8162 TclEvalEx + 1826
10  irmsde                        	0x000000010be77bad Tcl_FSEvalFileEx + 465
11  irmsde                        	0x000000010beeb442 Tk_MainEx + 926
12  irmsde                        	0x000000010bdc6823 main + 82
13  libdyld.dylib                 	0x00007fff8ef105fd start + 1
User Comments: hypnotoad added on 2015-03-02 22:37:10:
The latest trunk (as of 3/2/2015) produces:

Process:               irmsde [92958]
Path:                  /Users/USER/*/irmsde
Identifier:            irmsde
Version:               0
Code Type:             X86-64 (Native)
Parent Process:        bash [16635]
Responsible:           Terminal [518]
User ID:               501

Date/Time:             2015-03-02 17:35:55.499 -0500
OS Version:            Mac OS X 10.10.2 (14C109)
Report Version:        11
Anonymous UUID:        EAB60C7C-4834-FAFF-68F3-0BCB1A2842A1


Time Awake Since Boot: 22000 seconds

Crashed Thread:        0  Dispatch queue: com.apple.main-thread

Exception Type:        EXC_BAD_ACCESS (SIGSEGV)
Exception Codes:       EXC_I386_GPFLT

Thread 0 Crashed:: Dispatch queue: com.apple.main-thread
0   libobjc.A.dylib               	0x00007fff917b044f objc_release + 15
1   libobjc.A.dylib               	0x00007fff917aee8f (anonymous namespace)::AutoreleasePoolPage::pop(void*) + 575
2   com.apple.CoreFoundation      	0x00007fff954d2302 _CFAutoreleasePoolPop + 50
3   com.apple.Foundation          	0x00007fff93f38edf -[NSAutoreleasePool drain] + 153
4   tcl_faLgnM                    	0x000000010411893a -[TKApplication(TKNotify) nextEventMatchingMask:untilDate:inMode:dequeue:] + 286
5   tcl_faLgnM                    	0x0000000104118cfe TkMacOSXEventsCheckProc + 273
6   irmsde                        	0x00000001027ab35e Tcl_DoOneEvent + 316
7   irmsde                        	0x0000000102771b76 Tcl_VwaitObjCmd + 117
8   irmsde                        	0x00000001026fd7a2 TclNRRunCallbacks + 80
9   irmsde                        	0x00000001026d351f Rc4DecryptEvalObjCmd + 511 (rc4.c:479)
10  irmsde                        	0x00000001026fd7a2 TclNRRunCallbacks + 80
11  irmsde                        	0x00000001026fe9fd TclEvalEx + 1953
12  irmsde                        	0x000000010279fb89 Tcl_FSEvalFileEx + 465
13  irmsde                        	0x00000001027a5f37 Tcl_MainEx + 902
14  irmsde                        	0x00000001026ec375 main + 85 (tclAppInit.c:84)
15  libdyld.dylib                 	0x00007fff9b4155c9 start + 1

Thread 1:: Dispatch queue: com.apple.libdispatch-manager
0   libsystem_kernel.dylib        	0x00007fff8d7e6232 kevent64 + 10
1   libdispatch.dylib             	0x00007fff929c9a6a _dispatch_mgr_thread + 52

Thread 2:
0   libsystem_kernel.dylib        	0x00007fff8d7e53fa __select + 10
1   libsystem_pthread.dylib       	0x00007fff93a54268 _pthread_body + 131
2   libsystem_pthread.dylib       	0x00007fff93a541e5 _pthread_start + 176
3   libsystem_pthread.dylib       	0x00007fff93a5241d thread_start + 13

Thread 3:
0   libsystem_kernel.dylib        	0x00007fff8d7e04de mach_msg_trap + 10
1   libsystem_kernel.dylib        	0x00007fff8d7df64f mach_msg + 55
2   com.apple.CoreFoundation      	0x00007fff9550ab34 __CFRunLoopServiceMachPort + 212
3   com.apple.CoreFoundation      	0x00007fff95509ffb __CFRunLoopRun + 1371
4   com.apple.CoreFoundation      	0x00007fff95509858 CFRunLoopRunSpecific + 296
5   com.apple.AppKit              	0x00007fff9b9e933b _NSEventThread + 137
6   libsystem_pthread.dylib       	0x00007fff93a54268 _pthread_body + 131
7   libsystem_pthread.dylib       	0x00007fff93a541e5 _pthread_start + 176
8   libsystem_pthread.dylib       	0x00007fff93a5241d thread_start + 13

Thread 4:
0   libsystem_kernel.dylib        	0x00007fff8d7e594a __workq_kernreturn + 10
1   libsystem_pthread.dylib       	0x00007fff93a5240d start_wqthread + 13

Thread 5:
0   libsystem_kernel.dylib        	0x00007fff8d7e594a __workq_kernreturn + 10
1   libsystem_pthread.dylib       	0x00007fff93a5240d start_wqthread + 13

Thread 0 crashed with X86 Thread State (64-bit):
  rax: 0x8000000000000000  rbx: 0x00007fb2a239a010  rcx: 0x00007fb2a239af88  rdx: 0x00007fff5d55ad28
  rdi: 0x00007fb2986b8610  rsi: 0x00007fb2a2356280  rbp: 0x00007fff5d55b200  rsp: 0x00007fff5d55adb8
   r8: 0x000000000000007f   r9: 0x00007fb2984ccd80  r10: 0x00007fb2a2356290  r11: 0x0000000000000002
  r12: 0xa3a3a3a3a3a3a3a3  r13: 0x00007fff7dfe0070  r14: 0x00007fb2a03c1a98  r15: 0x00007fb2a03c1000
  rip: 0x00007fff917b044f  rfl: 0x0000000000010246  cr2: 0x00007fb299073800

hypnotoad added on 2014-09-05 16:47:17:
I am going to chaulk all of this up to some transient state of my Mac on that day. 24 hours later, the same setup is not crashing.

hypnotoad added on 2014-09-04 19:20:43:
The system will also occasionally crash with:

irmsde(9738,0x7fff7e426310) malloc: *** error for object 0x7f8debef6030: pointer being freed was not allocated
*** set a breakpoint in malloc_error_break to debug
Abort trap: 6