Home > other >  Why local two sockets to connect the same remote, local multiple socket handle is the same?
Why local two sockets to connect the same remote, local multiple socket handle is the same?

Time:11-17

I wrote epoll + on the server socket server, local write the client code compiled to a.out, local run multiple a.out, printed the same socket handle, strives for the bosses give advice or comments!
This is the code:

this is the results of the two binary, why two binary running at the same time, the client socket handle is the same?

local port looks two

CodePudding user response:

Settled, different processes have their own socket fd
  • Related