- Timestamp:
- 12/03/04 21:29:33 (20 years ago)
- Files:
-
- 1 modified
Legend:
- Unmodified
- Added
- Removed
-
pykota/trunk/pykota/ipp.py
r1901 r1972 22 22 # 23 23 # $Log$ 24 # Revision 1.2 2004/12/03 20:29:33 jalet 25 # ipp.py can now be run in standalone mode for testing purposes 26 # 24 27 # Revision 1.1 2004/11/06 22:35:58 jalet 25 28 # Added a miniparser for IPP messages (RFC 2910). The job-originating-host-name … … 174 177 raise PyKotaIPPError, "Unexpected end of IPP message." 175 178 179 if __name__ == "__main__" : 180 if len(sys.argv) < 2 : 181 print "usage : python ipp.py /var/spool/cups/c00005 (for example)\n" 182 else : 183 infile = open(sys.argv[1]) 184 message = IPPMessage(infile.read()) 185 infile.close() 186 print "Client hostname : %s" % message["job-originating-host-name"]