Commit a1e5c264 authored by Tim Wickberg's avatar Tim Wickberg
Browse files

Do not retry close() syscall on error.

Quoting part of the close() man page:

       Retrying  the  close() after a failure return is the wrong thing to do,
       since this may cause a reused file descriptor from another thread to be
       closed.   This  can  occur because the Linux kernel always releases the
       file descriptor early in the close operation, freeing it for reuse; the
       steps that may return an error, such as flushing data to the filesystem
       or device, occur only later in the close operation.
parent a51d1600
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment