1
0
Fork 0
mirror of https://github.com/NixOS/nix synced 2025-06-29 14:53:16 +02:00

Fix macOS warning

This commit is contained in:
Eelco Dolstra 2023-03-13 05:31:03 -07:00
parent 208c855124
commit fcd0b0fbd5

View file

@ -1070,12 +1070,14 @@ static pid_t doFork(bool allowVfork, std::function<void()> fun)
} }
#if __linux__
static int childEntry(void * arg) static int childEntry(void * arg)
{ {
auto main = (std::function<void()> *) arg; auto main = (std::function<void()> *) arg;
(*main)(); (*main)();
return 1; return 1;
} }
#endif
pid_t startProcess(std::function<void()> fun, const ProcessOptions & options) pid_t startProcess(std::function<void()> fun, const ProcessOptions & options)