Re: select.select and socket.setblocking

Discussion in 'Python' started by Jean-Paul Calderone, Dec 30, 2008.

  1. On Tue, 30 Dec 2008 15:55:51 -0500, Jean-Paul Calderone <> wrote:
    >On Tue, 30 Dec 2008 14:41:17 -0600, Grant Edwards <> wrote:
    >>On 2008-12-30, Francesco Bochicchio <> wrote:
    >>>3. AFAIK (sorry, I feel acronym-ly today ;), there is no difference in
    >>>select between blocking and non-blocking mode. The difference is in the
    >>>recv (again, assuming that you use TCP as protocol, that is AF_INET,
    >>>SOCK_STREAM), which in the blocking case would wait to receive all the
    >>>bytes that you requested,

    >>
    >>No, in blocking mode it will wait to receive _some_ data (1 or
    >>more bytes). The "requested" amount is strictly an upper
    >>limit: recv won't return more than the requested number of
    >>bytes, but it might return less.

    >
    >Hi Grant,
    >
    >I don't think you read Francesco's message carefully enough. :)


    Ah, no, it was I who didn't read carefully enough. Nevermind.

    Jean-Paul
    Jean-Paul Calderone, Dec 30, 2008
    #1
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Laszlo Nagy

    select.select and socket.setblocking

    Laszlo Nagy, Dec 30, 2008, in forum: Python
    Replies:
    12
    Views:
    1,162
    Roy Smith
    Jan 3, 2009
  2. Jean-Paul Calderone

    Re: select.select and socket.setblocking

    Jean-Paul Calderone, Dec 30, 2008, in forum: Python
    Replies:
    1
    Views:
    322
    Francesco Bochicchio
    Dec 31, 2008
  3. Laszlo Nagy
    Replies:
    1
    Views:
    4,767
    Mark Wooding
    Jan 27, 2009
  4. Jean-Paul Calderone
    Replies:
    0
    Views:
    948
    Jean-Paul Calderone
    Jan 27, 2009
  5. Laszlo Nagy
    Replies:
    0
    Views:
    531
    Laszlo Nagy
    Feb 1, 2009
Loading...

Share This Page