Free Trial

Safari Books Online is a digital library providing on-demand subscription access to thousands of learning resources.


  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint
Share this Page URL
Help

61. Sockets: Advanced Topics > Inheritance of Flags and Options Across accept()

Inheritance of Flags and Options Across accept()

Various flags and settings can be associated with open file descriptions and file descriptors (Relationship Between File Descriptors and Open Files). Furthermore, as described in Socket Options, various options can be set for a socket. If these flags and options are set on a listening socket, are they inherited by the new socket returned by accept()? We describe the details here.

On Linux, the following attributes are not inherited by the new file descriptor returned by accept():

  • The status flags associated with an open file description—the flags that can be altered using the fcntl() F_SETFL operation (Open File Status Flags). These include flags such as O_NONBLOCK and O_ASYNC.


  

You are currently reading a PREVIEW of this book.

                                                                                                                    

Get instant access to over $1 million worth of books and videos.

  

Start a Free 10-Day Trial


  
  • Safari Books Online
  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint