Calculate the available tcp buffer size - TCP-IP

This is a discussion on Calculate the available tcp buffer size - TCP-IP ; Hi, I come across a situation where i want to calculate the maximum amount of data that can be sent through the tcp connection at that particular instant . That is , i want to find a max. value such ...

+ Reply to Thread
Results 1 to 2 of 2

Thread: Calculate the available tcp buffer size

  1. Calculate the available tcp buffer size

    Hi,
    I come across a situation where i want to calculate the maximum amount
    of data that can be sent through the tcp connection at that particular
    instant . That is , i want to find a max. value such that when that
    many bytes are sent using the send() system call, the send() should
    send all the data. U can assumme that no data is going to be written
    into the connection from the other end.

    Thanks,
    Pradeep

  2. Re: Calculate the available tcp buffer size

    In article ,
    pradeep.kamalakumar@gmail.com (pradeep) wrote:

    > Hi,
    > I come across a situation where i want to calculate the maximum amount
    > of data that can be sent through the tcp connection at that particular
    > instant . That is , i want to find a max. value such that when that
    > many bytes are sent using the send() system call, the send() should
    > send all the data.


    What does this have to do with DNS? You posted it to
    comp.protocols.tcp-ip.domains. I'm redirecting followups to
    comp.protocols.tcp-ip.

    Anyway, I don't think there's a standard way to do this with the sockets
    API. If there's a Windows-specific way, I wouldn't know.

    Why do you think you need to know, anyway?

    > U can assumme that no data is going to be written
    > into the connection from the other end.


    Why would that even matter? The two directions of a socket are totally
    independent. Most implementations have separate send and receive
    buffers; if they both shared the same buffer memory, I think deadlocks
    would be more likely.

    --
    Barry Margolin, barmar@alum.mit.edu
    Arlington, MA
    *** PLEASE post questions in newsgroups, not directly to me ***

+ Reply to Thread