Topic: Cog crashes with certain SAP files

Re: Cog crashes with certain SAP files

Here's an excerpt from the log output, by the way:

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

Thread 0 Crashed:
0   ...rcompany.yourcocoaframework     0x01c142a4 gme_track_count + 0
1   ...yourcompany.yourcocoabundle     0x00634dcc +[GameContainer urlsForContainerURL:] + 132
2   org.cogx.cog                       0x00019f20 -[PlaylistLoader insertURLs:atIndex:sort:] + 800
3   org.cogx.cog                       0x0000391c -[PlaylistController tableView:acceptDrop:row:dropOperation:] + 560
4   com.apple.AppKit                   0x93b92870 -[NSTableView performDragOperation:] + 160
5   com.apple.AppKit                   0x939fef14 NSCoreDragReceiveProc + 864
6   com.apple.HIServices               0x9185bde8 DoDropMessage + 96
7   com.apple.HIServices               0x9185d28c CoreDragMessageHandler + 1332
8   com.apple.CoreFoundation           0x90826000 __CFMessagePortPerform + 304
9   com.apple.CoreFoundation           0x907ec568 __CFRunLoopDoSource1 + 152
10  com.apple.CoreFoundation           0x907dec80 __CFRunLoopRun + 1556
11  com.apple.CoreFoundation           0x907de2b0 CFRunLoopRunSpecific + 268
12  com.apple.HIToolbox                0x932bbb20 RunCurrentEventLoopInMode + 264
13  com.apple.HIToolbox                0x932bb1b4 ReceiveNextEventCommon + 380
14  com.apple.HIToolbox                0x932bb020 BlockUntilNextEventMatchingListInMode + 96
15  com.apple.AppKit                   0x937a0734 _DPSNextEvent + 384
16  com.apple.AppKit                   0x937a03f8 -[NSApplication nextEventMatchingMask:untilDate:inMode:dequeue:] + 116
17  com.apple.AppKit                   0x9379c93c -[NSApplication run] + 472
18  com.apple.AppKit                   0x9388d458 NSApplicationMain + 452
19  org.cogx.cog                       0x00002564 _start + 760
20  org.cogx.cog                       0x00002268 start + 48

Re: Cog crashes with certain SAP files

The GME plugin hasn't changed that much. It looks like Cog's just failing to check for an error, meaning it'd be unable to play the file even if it didn't crash.

The error GME gives is:
Error loading file: /Users/vspader/Downloads/ASMA/Unknown/Bach_Mix.sap Digimusic not supported

The GME library Cog uses to read these files just doesn't support this type.