Thread: How does send and recv buffer work Linux IPv6?

  1. #1
    Registered User
    Join Date
    Jul 2017
    Posts
    28

    How does send and recv buffer work Linux IPv6?

    When the server sends the data in its buffer, does it append to the client's buffer without any EOL character?

    When the client receives the characters from the buffer does it remove the characters from the front of the buffer (FIFO system)?

    Where is the data stored before the client receives it, and can this storage overflow?

    Thanks.

  2. #2
    and the hat of int overfl Salem's Avatar
    Join Date
    Aug 2001
    Location
    The edge of the known universe
    Posts
    37,436
    > How does send and recv buffer work Linux IPv6?
    The same way as it does in IPv4.

    If you send 10 bytes, you get 10 bytes (eventually), in the order you sent them.

    > does it append to the client's buffer without any EOL character?
    No.

    > When the client receives the characters from the buffer does it remove the characters from the front of the buffer (FIFO system)?
    Yes.

    > Where is the data stored before the client receives it, and can this storage overflow?
    No, flow control will back up across the link to stop the sender transmitting.
    If you dance barefoot on the broken glass of undefined behaviour, you've got to expect the occasional cut.
    If at first you don't succeed, try writing your phone number on the exam paper.

  3. #3
    Registered User
    Join Date
    Jul 2017
    Posts
    28
    Quote Originally Posted by Salem View Post
    > How does send and recv buffer work Linux IPv6?
    > does it append to the client's buffer without any EOL character?
    No.
    So, when you send data to the client, it overwrites data starting at the beginning of the client's buffer each time, instead of appending?

    I'm asking because the IPv6 program that I wrote is giving me some weird behavior and I think its the buffer getting corrupted, since my server and client do not run at the same rate.

  4. #4
    and the hat of int overfl Salem's Avatar
    Join Date
    Aug 2001
    Location
    The edge of the known universe
    Posts
    37,436
    There is something wrong with YOUR code.
    Millions are using IPv6 without having this problem.
    If you dance barefoot on the broken glass of undefined behaviour, you've got to expect the occasional cut.
    If at first you don't succeed, try writing your phone number on the exam paper.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Send() and Recv()
    By Rodaxoleaux in forum Networking/Device Communication
    Replies: 0
    Last Post: 12-07-2011, 12:57 PM
  2. Send/Recv
    By brietje698 in forum Networking/Device Communication
    Replies: 13
    Last Post: 12-13-2007, 10:16 PM
  3. send and recv
    By DeadManWalking in forum C Programming
    Replies: 1
    Last Post: 12-04-2005, 09:17 AM
  4. Using recv() and send()
    By Sam_bham in forum C Programming
    Replies: 3
    Last Post: 06-08-2004, 04:36 PM
  5. recv/send
    By Wisefool in forum Networking/Device Communication
    Replies: 8
    Last Post: 10-26-2003, 06:40 PM

Tags for this Thread