TreeviewCopyright © aleen42 all right reserved, powered by aleen42

Accept Back

  • accept the connection of clients
  • new socket descriptor is different from the old one
    • The old socket descriptor is to listen to the connections of clients.
    • The new socket descriptor is to handle communications between the server and the client.
  • accept method will be blocked until complete a connection
int accept(int sockfd, struct sockaddr* clientaddr, int* addrlen)
  • sockfd: socket描述符
  • clientaddr: 客戶端地址
  • addrlen: 地址長度
return value
  • >0: new socket descriptor
  • -1: failure
  • errno: wrong code
Empty Comments
Sign in GitHub

As the plugin is integrated with a code management system like GitLab or GitHub, you may have to auth with your account before leaving comments around this article.

Notice: This plugin has used Cookie to store your token with an expiration.