Sudden crash with new Juce

I recently upgraded an application from Juce 1.21 to 1.38. After modifying here and there everything appears to run smoothly - but only appears. Lately, I’ve experienced mysterious crashes, not seen before the Juce upgrade. The following is a print of the relevant parts of the crash report (sorry about the “dump”). There are some other threads running, so this might be cause of stuff - but appearently not in the earlier Juce version. Any hints, similar experiences or stuff I should know about A complete fix perhaps…? :slight_smile:

-Thanks in advance!

Date/Time: 2006-11-15 14:53:10.221 +0100
OS Version: 10.4.8 (Build 8L127)
Report Version: 4

Command:
Path: /Applications//Contents/MacOS/
Parent: WindowServer [113]

Version: 1.0.3f445 (1.0.3f445)

PID: 688
Thread: 0

Exception: EXC_BAD_ACCESS (0x0001)
Codes: KERN_INVALID_ADDRESS (0x0001) at 0x14900a00

Thread 0 Crashed:
0 com.apple.CoreGraphics 0x9038cbb4 shape_intersect + 1100
1 com.apple.CoreGraphics 0x9038c6d4 CGSIntersectRegion + 156
2 com.apple.HIToolbox 0x93230c60 HIShapeCreateIntersection + 60
3 com.apple.HIToolbox 0x93231d0c HIView::BuildAggregateInvalidRegion(__HIShape*) + 256
4 com.apple.HIToolbox 0x93231c7c HIView::BuildAggregateInvalidRegion(__HIShape*) + 112
5 com.apple.HIToolbox 0x93231c7c HIView::BuildAggregateInvalidRegion(__HIShape*) + 112
6 com.apple.HIToolbox 0x93231b9c HIView::DetermineAreaToPaint(OpaqueGrafPtr*, unsigned long, __HIShape const*) + 52
7 com.apple.HIToolbox 0x933923a0 HIView::DrawComposited(short, OpaqueGrafPtr*, __HIShape const*, unsigned long, HIView*, CGContext*) + 168
8 com.apple.HIToolbox 0x934adbfc FlushWindowObject(WindowData*, void**, unsigned char) + 548
9 com.apple.HIToolbox 0x93223eac FlushAllWindows() + 204
10 com.apple.CoreFoundation 0x907dc73c __CFRunLoopDoObservers + 352
11 com.apple.CoreFoundation 0x907dc464 CFRunLoopRunSpecific + 244
12 com.apple.HIToolbox 0x93208740 RunCurrentEventLoopInMode + 264
13 com.apple.HIToolbox 0x93207d4c ReceiveNextEventCommon + 244
14 com.apple.HIToolbox 0x9330c940 ReceiveNextEventInMode + 72
15 de. 0x000b26d0 juce::juce_dispatchNextMessageOnSystemQueue(bool) + 68
16 de… 0x000a0aa4 juce::essageManager::dispatchNextMessage(bool, bool*) + 96
17 de. 0x000a0c74 juce::MessageManager::runDispatchLoop() + 36
18 de. 0x000a018c juce::JUCEApplication::main(juce::String&, juce::JUCEApplication*) + 612
19 de. 0x000a0470 juce::JUCEApplication::main(int, char**, juce::JUCEApplication*) + 132
20 de. 0x0000266c _start + 760
21 de. 0x00002370 start + 48

Thread 0 crashed with PPC Thread State 64:
srr0: 0x000000009038cbb4 srr1: 0x100000000000d030 vrsave: 0x0000000000000000
cr: 0x44002448 xer: 0x0000000000000000 lr: 0x000000009038c844 ctr: 0x0000000090003728
r0: 0x0000000000000200 r1: 0x00000000bffff350 r2: 0x0000000000000002 r3: 0x0000000000000000
r4: 0x0000000000000000 r5: 0x00000000bffff390 r6: 0x0000000000000001 r7: 0x00000000bffff394
r8: 0x0000000001203eaf r9: 0x00000000011f55d0 r10: 0x00000000011f55cc r11: 0x0000000044002482
r12: 0x0000000090003138 r13: 0x0000000000000000 r14: 0x00000000bffff394 r15: 0x00000000bffff390
r16: 0x0000000005200a00 r17: 0x00000000052666d8 r18: 0x0000000000000000 r19: 0x00000000011f55cc
r20: 0x0000000000000020 r21: 0x000000007fffffff r22: 0x00000000a038eef0 r23: 0x00000000011f5580
r24: 0x00000000052666e8 r25: 0x0000000000000000 r26: 0x0000000000000000 r27: 0x0000000014900a00
r28: 0x0000000005200a08 r29: 0x00000000011e7c9c r30: 0x00000000052666e8 r31: 0x000000009038c780

Model: PowerMac7,2, BootROM 5.1.5f2, 1 processors, PowerPC 970 (2.2), 1.8 GHz, 512 MB
Graphics: GeForce FX 5200, GeForce FX 5200, AGP, 64 MB
Memory Module: DIMM0/J11, 256 MB, DDR SDRAM, PC3200U-30330
Memory Module: DIMM1/J12, 256 MB, DDR SDRAM, PC3200U-30330
Modem: MicroDash, Euro, V.92, 1.0F, APPLE VERSION 2.6.6
Network Service: Built-in Ethernet, Ethernet, en0
Serial ATA Device: ST3160023AS, 149.05 GB
Parallel ATA Device: SONY DVD RW DW-U10A,
USB Device: USB-PS/2 Optical Mouse, Logitech, Up to 1.5 Mb/sec, 500 mA
USB Device: Hub in Apple Pro Keyboard, Mitsumi Electric, Up to 12 Mb/sec, 500 mA
USB Device: Apple Pro Keyboard, Mitsumi Electric, Up to 12 Mb/sec, 250 mA
FireWire Device: unknown_device, unknown_value, Unknown
FireWire Device: Konnekt24D, TC Electronic, Up to 200 Mb/sec

That crash isn’t actually in juce code at all - it’s deep in apple’s own stuff…

Most likely there’s some kind of memory corruption going on, but impossible to say any more from this info. It could be in your code, or in juce. I’ve not seen anything similar.

The mac windowing has all completely changed since 1.21 though. If you could get some code that reproduces the crash I’d be happy to take a look.

Thanks for your reply. I’m afraid it’s somewhat impossible to isolate the bug. It is a biig program, and it actually rarely crashes - so finding out what, when, how and why something goes wrong… Well. If I get a hint of the problem, and can reproduce it reliably, I’ll let you know!

-Andreas

Hi Amygdala, did you ever find out what caused this crash? A friend of mine had a similar problem too on his MacBookPro2.