[haiku-bugs] [Haiku] #15081: listen() causes a socket to be "connected"

  • From: "Haiku" <trac@xxxxxxxxxxxx>
  • To: undisclosed-recipients: ;
  • Date: Wed, 22 May 2019 08:19:30 -0000

#15081: listen() causes a socket to be "connected"
------------------------------------+------------------------------
 Reporter:  leorize                 |        Owner:  axeld
     Type:  bug                     |       Status:  new
 Priority:  normal                  |    Milestone:  Unscheduled
Component:  Network & Internet/TCP  |      Version:  R1/Development
 Keywords:                          |   Blocked By:
 Blocking:                          |  Has a Patch:  0
 Platform:  All                     |
------------------------------------+------------------------------
 Calling `listen()` will assign a 0.0.0.0 peer to the socket, where as no
 connection has been accepted yet.

 The demo below will describe the problem. To run:

 {{{
 $ gcc -o peerless -lnetwork peerless.c
 $ ./peerless
 }}}

 Expected result:

 Exit code 0, no output

 Got:

 {{{
 Expected ENOTCONN, got 0
 }}}

-- 
Ticket URL: <https://dev.haiku-os.org/ticket/15081>
Haiku <https://dev.haiku-os.org>
The Haiku operating system.

Other related posts: