telnet --- sockets ?

Grant Edwards grante at visi.com
Tue Jan 22 18:00:08 EST 2002


In article <3c4de752_1 at corp.newsgroups.com>, Joshua Muskovitz wrote:
> "maximilianscherr" <MaximilianScherr at T-Online.de> wrote in message
> news:mailman.1011734492.16085.python-list at python.org...
>> ...thewholeconnstuff
>> s.send("sservinfo\n")
>> res = s.recv(128)
>> print res
>>
>> output: no output, it hangs!, so -> DOESN'T WORK
> 
> Because sockets are not instantaneous, 

Ah, he forgot to set the SO_INSTANEOUS flag!

;)

> so the data will probably not be there when you are ready to
> call s.recv(). After following a number of your posts related
> to sockets, it is clear that you don't really understand how
> they work.  I stongly recommend _UNIX Network Programming_ by
> W. Richard Stevens as a book to teach you more than you want to
> know about them.

It may be more than you want to know -- but, when it comes to
sockets: more than you want to know is pretty much what it
takes to do it right.

-- 
Grant Edwards                   grante             Yow!  All this time I've
                                  at               been VIEWING a RUSSIAN
                               visi.com            MIDGET SODOMIZE a HOUSECAT!



More information about the Python-list mailing list