xxyzz/ostep-hw

chapter 5 Q 2

Closed this issue · 1 comments

If you write open() before fork(), as indicated in the question, both processes will append to the end of th file, not overwrite.

xxyzz commented

I updated the answer in 8fbf5e1. It depends on the scheduler, maybe they will write sequentially in most cases but not all the time.