HN
Hacker News
Top
New
Best
Ask
Show
Jobs
Comment by klempner | Hacker News Reader
Parent
Full thread
klempner
·
How exactly does this interact with fork()?
View on HN
jart
·
Your libc fork() implementation will lock the stdio mutexes automatically before calling SYS_fork, so the code I wrote in my comment would be fork safe. Your child process would need to spawn the flusher thread again if it's desired though.
Reply on news.ycombinator.com