Skip to content

Commit

Permalink
Fix #545 - crash in macOS ls when using a non-objc app
Browse files Browse the repository at this point in the history
  • Loading branch information
radare committed Jan 16, 2024
1 parent cf10a0a commit 9f5d92e
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/agent/lib/darwin/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -301,6 +301,9 @@ export class IOSPathTransform extends PathTransform {
}

_fillVirtualDirs(): void {
if (!hasMainLoop()) {
return;
}
const pool = this.api.NSAutoreleasePool.alloc().init();
const appHome: string = new ObjC.Object(this.api.NSHomeDirectory()).toString();
const appBundle: string = this.api.NSBundle.mainBundle().bundlePath().toString();
Expand Down

0 comments on commit 9f5d92e

Please sign in to comment.