Python TimeServer (RFC 868)

Jeff jam at quark.emich.edu
Wed Sep 29 00:07:05 EDT 1999


On Wed, Sep 29, 1999 at 02:40:30AM +0000, Benjamin Schollnick wrote:
> 	I believe that I need to send it as a binary value (a 4 byte 
> integer), instead of a 
> 	string... But can't figure out a way to do this...?
> 

hmm.. well, if you are already opening the socket yourself, and using
'write' to send data to it, can't you just run 'long(foo)' and write that to
the socket instead of the text version? perhaps something with the 'struct'
module is in order.. you'll need to know the byte order (which the RFC
should give you) before mucking around with writing binary data.

just a suggestion.

regards,
J
-- 
|| visit gfd <http://quark.newimage.com/> 
|| psa member #293 <http://www.python.org/> 
|| New Image Systems & Services, Inc. <http://www.newimage.com/>




More information about the Python-list mailing list