Is your app sandboxed?
Yes, it is sandboxed.
Post
Replies
Boosts
Views
Activity
Thanks eskimo,
The semaphore & shared memory issue has been solved.
Could I ask one more related question in this thread? The app is sandboxed in this situation. I use posix_spawn to open another instance of the same application. I get the pid successfully, but i could not find the Window. It works when it is a non-sandboxed app. Find nothing about this in the page IPC and POSIX Semaphores and Shared Memory - https://developer.apple.com/library/archive/documentation/Security/Conceptual/AppSandboxDesignGuide/AppSandboxInDepth/AppSandboxInDepth.html#//apple_ref/doc/uid/TP40011183-CH3-SW24
Thanks again gracefully.
When then user click button on the window, it would trigger posix_spawn(&pid, argv[0], NULL, NULL, argv, env) to start another process of the same program. In sandbox situation. The triggered window did not show up.
Best Regards
Yeeees, totally correct.
Best Regards
Thanks Eskimo,
I am working on a cross-platform infra project. We try to follow things we have done under linux.
One more details I forget to mention.
When the app is sandboxed, I can do the same thing using fork().
Table - https://developer.apple.com/forums/content/attachment/25fad295-0b00-472c-b6d6-e5bfbc44e5f1
Thanks again.
Hi eskimo,
The system attaches entitlements to a process when it execs, so a simple fork doesn’t trigger this issue. A posix_spawn is (by default) a fork/exec, and it’s the exec that’s causing you problems.
macOS and Linux have very different architectures when it comes to GUI process management.
Thanks for your explaination. I think this thread could be closed.
Our target is to make the app one-progress-multiple-window. We use flutter, but it does not support this feature currently. So we must find the workaround.
Best Regards