Crash for NativePath or ShellPath in El Capitan

Hi,

got one customer who gets nice crashes when accessing NativePath or ShellPath.

Thread 10 Crashed:
0 com.xojo.XojoFramework 0x017a3d09 FileShellPathGetter + 73
1 com.mothsoftware.mailarchiverx 0x0009cbaf FolderItem.ShellPath.Get%s%oi4 + 71
2 com.mothsoftware.mailarchiverx 0x00c8713e MakeMailboxMail.TravelDownAccountMailboxes%o%ooA1s + 546
3 com.mothsoftware.mailarchiverx 0x00c83236 MakeMailboxMail.get%v%o + 3717
4 com.mothsoftware.mailarchiverx 0x00c816bf MakeMailboxFromString.get%v%o + 207
5 com.mothsoftware.mailarchiverx 0x00c753d1 MailboxIterator.nextObject%o%o + 465
6 com.mothsoftware.mailarchiverx 0x00c9ea3f ArchiveThread.DoWork%%o + 1464
7 com.mothsoftware.mailarchiverx 0x00c9e427 ArchiveThread.Event_Run%%o + 56
8 com.xojo.XojoFramework 0x017dd8ba 0x16bb000 + 1190074
9 libsystem_pthread.dylib 0x9bfa9794 _pthread_body + 138
10 libsystem_pthread.dylib 0x9bfa970a _pthread_start + 155
11 libsystem_pthread.dylib 0x9bfa6fa6 thread_start + 34

Any ideas? The calls to NativePath or as alternative ShellPath are used for debugging here because the customer has problems archiving one mailbox.

Xojo 2014r2. There is no possibility to upgrade this at the moment.

Mit freundlichen Grüßen/Regards

Trixi Willius

http://www.mothsoftware.com
Mail Archiver X: The email archiving solution for professionals

[quote=218638:@Beatrix Willius]Hi,

got one customer who gets nice crashes when accessing NativePath or ShellPath.

Thread 10 Crashed:
0 com.xojo.XojoFramework 0x017a3d09 FileShellPathGetter + 73
1 com.mothsoftware.mailarchiverx 0x0009cbaf FolderItem.ShellPath.Get%s%oi4 + 71
2 com.mothsoftware.mailarchiverx 0x00c8713e MakeMailboxMail.TravelDownAccountMailboxes%o%ooA1s + 546
3 com.mothsoftware.mailarchiverx 0x00c83236 MakeMailboxMail.get%v%o + 3717
4 com.mothsoftware.mailarchiverx 0x00c816bf MakeMailboxFromString.get%v%o + 207
5 com.mothsoftware.mailarchiverx 0x00c753d1 MailboxIterator.nextObject%o%o + 465
6 com.mothsoftware.mailarchiverx 0x00c9ea3f ArchiveThread.DoWork%%o + 1464
7 com.mothsoftware.mailarchiverx 0x00c9e427 ArchiveThread.Event_Run%%o + 56
8 com.xojo.XojoFramework 0x017dd8ba 0x16bb000 + 1190074
9 libsystem_pthread.dylib 0x9bfa9794 _pthread_body + 138
10 libsystem_pthread.dylib 0x9bfa970a _pthread_start + 155
11 libsystem_pthread.dylib 0x9bfa6fa6 thread_start + 34

Any ideas? The calls to NativePath or as alternative ShellPath are used for debugging here because the customer has problems archiving one mailbox.

Xojo 2014r2. There is no possibility to upgrade this at the moment.

Mit freundlichen Grüßen/Regards

Trixi Willius

http://www.mothsoftware.com
Mail Archiver X: The email archiving solution for professionals[/quote]

Can you file a bug report with the full crash log? And do you have any idea where this FolderItem is supposed to be pointing at on disk?

[quote=218638:@Beatrix Willius]Hi,

got one customer who gets nice crashes when accessing NativePath or ShellPath.
[/quote]

It would be of interest to know which path you are trying to access. Maybe the area you are trying to access is now off limit in EC. Have you tried it yourself ? Does it happen only on your client machine ?

@Michel Bujardet : the paths are in in user/Library/Mail/V3/account_or_mailbox. No, the code doesn’t crash for me - either on my MacBook Air or VMWare. So far this is the first customer to have this problem.

@Joe Ranieri : the Feeback case is <https://xojo.com/issue/41060>.

That would be completely off limit to a sandboxed program. However, here, I was able to write to that quite fine in my space. However, it crashes right away if I try to write to guest. Could it be that your user is running the program from another account ?

I’m only trying to read and not write. The app is not sandboxed. I’ll ask the user what typ of account he has.

had the machine gone to sleep with the app running ?

The crash immediately happens after clicking a button in my app. So I doubt that the machine has gone to sleep. Also I’m using a declare that the computer doesn’t go to sleep at all while my app is working.

So, looking at the crash log, the best way to debug this is to run the application with Guard Malloc enabled. Unfortunately this will require launching the program from the command line, like so:

[quote]export DYLD_INSERT_LIBRARIES=/usr/lib/libgmalloc.dylib
‘/Applications/Mail Archiver X/Mail Archiver X.app/Contents/MacOS/Mail Archiver X’[/quote]

OK
was just a hunch after a couple other reports came in that were kind of similar but they were dealing with network volumes & others that had gone offline

Checking everything never hurts.

@Joe Ranieri : I almost overlooked your comment. Can my customer do this out of the box or is XCode required for guard malloc?

I believe it is installed by default.

@Joe Ranieri : very good. I’ll do this with the customer tomorrow and report back.

Here is the result:

Tests-iMac:~ klausnachtigall$ export DYLD_INSERT_LIBRARIES=/usr/lib/libgmalloc.dylib
Tests-iMac:~ klausnachtigall$ ‘/Applications/Mail Archiver X/Mail Archiver X.app/Contents/MacOS/Mail Archiver X’
GuardMalloc[Mail Archiver X-70478]: Allocations will be placed on 16 byte boundaries.
GuardMalloc[Mail Archiver X-70478]: - Some buffer overruns may not be noticed.
GuardMalloc[Mail Archiver X-70478]: - Applications using vector instructions (e.g., SSE) should work.
GuardMalloc[Mail Archiver X-70478]: version 108
Oct 9 08:07:05 Mail Archiver X[70478] : void CGSUpdateManager::log() const: conn 0xeea7 token 0x1ffffffffffe85
Oct 9 08:07:05 Mail Archiver X[70478] : Backtrace (at 7927.66):
Oct 9 08:07:05 Mail Archiver X[70478] : void CGSUpdateManager::log() const: 0 CoreGraphics 0x95364d8f CGSDisableUpdateToken + 228
Oct 9 08:07:05 Mail Archiver X[70478] : void CGSUpdateManager::log() const: 1 AppKit 0x90d11a51 ___disable_updates_sync_block_invoke_2 + 19
Oct 9 08:07:05 Mail Archiver X[70478] : void CGSUpdateManager::log() const: 2 libdispatch.dylib 0x9da2e7e7 dispatch_client_callout + 50
Oct 9 08:07:05 Mail Archiver X[70478] : void CGSUpdateManager::log() const: 3 libdispatch.dylib 0x9da300b8 dispatch_barrier_sync_f_invoke + 61
Oct 9 08:07:05 Mail Archiver X[70478] : void CGSUpdateManager::log() const: 4 libdispatch.dylib 0x9da30074 dispatch_barrier_sync_f + 98
Oct 9 08:07:05 Mail Archiver X[70478] : void CGSUpdateManager::log() const: 5 libdispatch.dylib 0x9da3a6cb dispatch_barrier_sync + 54
Oct 9 08:07:05 Mail Archiver X[70478] : void CGSUpdateManager::log() const: 6 AppKit 0x90d1193a NSCGSDisableUpdates + 1302
Oct 9 08:07:05 Mail Archiver X[70478] : void CGSUpdateManager::log() const: 7 AppKit 0x90d1134f NSCGSTransactionRunPreCommitActionsForOrder
+ 159
Oct 9 08:07:05 Mail Archiver X[70478] : void CGSUpdateManager::log() const: 8 AppKit 0x90d1129e NSCGSTransactionRunPreCommitActions
+ 26
Oct 9 08:07:05 Mail Archiver X[70478] : void CGSUpdateManager::log() const: 9 AppKit 0x90cf2467 -[NSCGSTransaction addActionWithOrder:usingBlock:] + 236
Oct 9 08:07:05 Mail Archiver X[70478] : void CGSUpdateManager::log() const: 10 AppKit 0x90cf2361 NSCGSTransactionAddAction + 115
Oct 9 08:07:05 Mail Archiver X[70478] : void CGSUpdateManager::log() const: 11 AppKit 0x90cf1d41 NSCGSWindowBackingStoreMark
+ 266
Oct 9 08:07:05 Mail Archiver X[70478] : void CGSUpdateManager::log() const: 12 AppKit 0x90cf1c2d -[_NSCGSWindowBackingStore setAttached:] + 43
Oct 9 08:07:05 Mail Archiver X[70478] : void CGSUpdateManager::log() const: 13 AppKit 0x90cf1951 -[NSCGSWindow(NSCGSWindowBackingStore) setHasBackingStore:] + 89
Oct 9 08:07:05 Mail Archiver X[70478] : void CGSUpdateManager::log() const: 14 AppKit 0x90dcf8d0 _NSCreateWindowWithOpaqueShape2 + 120
Oct 9 08:07:05 Mail Archiver X[70478] : void CGSUpdateManager::log() const: 15 AppKit 0x90dce343 -[NSWindow _commonAwake] + 2259
Oct 9 08:07:05 Mail Archiver X[70478] : void CGSUpdateManager::log() const: 16 AppKit 0x90bc8bf9 -[NSWindow _commonInitFrame:styleMask:backing:defer:] + 807
Oct 9 08:07:05 Mail Archiver X[70478] : void CGSUpdateManager::log() const: 17 AppKit 0x90bc71c4 -[NSWindow _initContent:styleMask:backing:defer:contentView:] + 1789
Oct 9 08:07:05 Mail Archiver X[70478] : void CGSUpdateManager::log() const: 18 AppKit 0x90c471f8 -[NSPanel _initContent:styleMask:backing:defer:contentView:] + 87
Oct 9 08:07:05 Mail Archiver X[70478] : void CGSUpdateManager::log() const: 19 AppKit 0x90bc6abd -[NSWindow initWithContentRect:styleMask:backing:defer:] + 72
Oct 9 08:07:05 Mail Archiver X[70478] : void CGSUpdateManager::log() const: 20 AppKit 0x90c47191 -[NSPanel initWithContentRect:styleMask:backing:defer:] + 94
Oct 9 08:07:05 Mail Archiver X[70478] : void CGSUpdateManager::log() const: 21 XojoFramework 0x0170252c ExecuteAppleScript + 303180
Oct 9 08:07:05 Mail Archiver X[70478] : void CGSUpdateManager::log() const: 22 XojoFramework 0x017fcde2 MDIWindowDestructor + 818
Oct 9 08:07:05 Mail Archiver X[70478] : void CGSUpdateManager::log() const: 23 XojoFramework 0x0173d6c3 RuntimeDecodeHex + 435
Oct 9 08:07:05 Mail Archiver X[70478] : void CGSUpdateManager::log() const: 24 XojoFramework 0x0173e34b EmbedWithinInternal + 1963
Oct 9 08:07:05 Mail Archiver X[70478] : void CGSUpdateManager::log() const: 25 XojoFramework 0x0173d7f8 CreateStandAloneWindow + 280
Oct 9 08:07:05 Mail Archiver X[70478] : void CGSUpdateManager::log() const: 26 XojoFramework 0x017dd7cd RuntimeCreateWindow + 477
Oct 9 08:07:05 Mail Archiver X[70478] : void CGSUpdateManager::log() const: 27 Mail Archiver X 0x0003cd43 Window.__Init%%o + 91
Oct 9 08:07:05 Mail Archiver X[70478] : void CGSUpdateManager::log() const: 28 XojoFramework 0x017d1b16 RuntimeNewObject + 438
Oct 9 08:07:05 Mail Archiver X[70478] : void CGSUpdateManager::log() const: 29 XojoFramework 0x017d1b0a RuntimeNewObject + 426
Oct 9 08:07:05 Mail Archiver X[70478] : void CGSUpdateManager::log() const: 30 XojoFramework 0x017d1a4a RuntimeNewObject + 234
Oct 9 08:07:05 Mail Archiver X[70478] : void CGSUpdateManager::log() const: 31 Mail Archiver X 0x00e3d35d ProgressWindowManager.Constructor%%os + 220
Assertion failed: (addr != MAP_FAILED), function _open_and_mmap_for_reading, file /BuildRoot/Library/Caches/com.apple.xbs/Sources/LanguageIdentifier/LanguageIdentifier-122/LanguageIdentifier.c, line 607.
Abort trap: 6