title: Closing socket file descriptor after EPIPE
body: <p>After ignoring SIGPIPE with a call to signal(), there is a possibility that a write() call will fail with errno set equal to EPIPE. Do I still have to close the file descriptor like in the example below?</p>
  
  <pre><code>if (write(sock_fd, buf, len) &lt; 0) {
      if (errno == EPIPE) {
          close(sock_fd);
      }
  }
  </code></pre>