Can a program call fflush() on the same FILE* concurrently?
Streams in C1 are thread-safe2. Functions are required to lock the stream before accessing it3. The fflush function is thread-safe and may be called from any thread at any time, as long as the stream is an output stream or an update stream4. 1 As per the current standard, which is C11. 2 (Quoted from: … Read more