This is an archive of the discontinued Mercurial Phabricator instance.

procutil: try and avoid angering CoreFoundation on macOS
ClosedPublic

Authored by durin42 on Dec 12 2019, 12:38 PM.

Details

Summary

We've seen failures like this:

objc[57662]: +[__NSCFConstantString initialize] may have been in progress in another thread when fork() was called.
objc[57662]: +[__NSCFConstantString initialize] may have been in progress in another thread when fork() was called. We cannot safely call it or ignore it in the fork() child process. Crashing instead. Set a breakpoint on objc_initializeAfterForkError to debug.

I think this is due to forking off some background processes during
hg update or similar. I don't have any conclusive proof this is the
fork() call that's to blame, but it's the most likely one since the
regular hg update codepath uses the other fork() invocation (via
workers) and we don't get this report from non-Google macOS users.

Ugh.

Diff Detail

Repository
rHG Mercurial
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.

Event Timeline

durin42 created this revision.Dec 12 2019, 12:38 PM
durin42 updated this revision to Diff 18755.Dec 16 2019, 9:27 AM
pulkit accepted this revision.Dec 17 2019, 6:58 AM
This revision is now accepted and ready to land.Dec 17 2019, 6:58 AM
This revision was automatically updated to reflect the committed changes.