Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 1085483
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 16, 20262026-05-16T22:41:42+00:00 2026-05-16T22:41:42+00:00

I have a TCP server that creates a (blocking) socket, waits until it is

  • 0

I have a TCP server that creates a (blocking) socket, waits until it is available for reading using select(), then calls accept() and starts reading the data.
Here is an example (not mine) illustrating the concept.

The question is, at what points of TCP handshake does select() and accept() calls return?

TCP 3-way handshake

Ubuntu Hardy, if it matters.
2.6.31-14-server #48ya1 SMP Fri Apr 2 15:43:25 MSD 2010 x86_64 GNU/Linux

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-16T22:41:42+00:00Added an answer on May 16, 2026 at 10:41 pm

    The select() returns, indicating that the listening socket is “readable”, immediately after the last packet in that diagram is recieved.

    If you had blocked on accept() instead, it would have returned at that same point (when the server socket transitions to ESTABLISHED).

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have developed a Java server using Eclipse that accepts TCP socket connection from
I have a server that connects to multiple clients using TCP/IP connections, using C
Currently I have an application that connects to a Terminal Server over TCP/IP using
I have a TCP server app that is written in C#. I accept TCP
I have a server application that receives some special TCP packet from a client
I have a MIDlet that sends TCP messages over the network to a server
I have a Client program by tcp connection that send data to a server.
I have written a TCP server implementation using which I created an application which
I have two utilities written in C++, TCP/IP server and client that I have
I have a small TCP server that listens on a port. While debugging it's

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.