[Oval-commits] r228 - trunk/oval-server
Pavel Vinogradov
blaze-guest at alioth.debian.org
Thu Aug 23 20:29:42 UTC 2007
Author: blaze-guest
Date: 2007-08-23 20:29:42 +0000 (Thu, 23 Aug 2007)
New Revision: 228
Modified:
trunk/oval-server/oval-monitor.py
Log:
Small fixes in oval-monitor'
Modified: trunk/oval-server/oval-monitor.py
===================================================================
--- trunk/oval-server/oval-monitor.py 2007-08-23 20:10:33 UTC (rev 227)
+++ trunk/oval-server/oval-monitor.py 2007-08-23 20:29:42 UTC (rev 228)
@@ -17,7 +17,7 @@
print """usage: python %s [-h] [-c <config>] [-a <agent ip>] [-d <dsa id>]
\t-h\tthis help
\t-c\tpath to config file (by default oval-server.cfg
-\t-a\tagent ip address
+\t-a\tagent id
\t-d\tDebian Security Annnounce id
""" % prog
@@ -118,10 +118,16 @@
reporter = Report (opts['-c'])
if opts.has_key ('-a'):
- reporter.reportAgent (int(opts['-a']))
+ try:
+ reporter.reportAgent (int(opts['-a']))
+ except ValueError:
+ print 'Please enter numeric agent ID'
else:
if opts.has_key ('-d'):
- reporter.reportDSA (int(opts['-d']))
+ try:
+ reporter.reportDSA (int(opts['-d']))
+ except ValueError:
+ print 'Please enter numeric DSA id'
else:
reporter.reportFull ()
More information about the Oval-commits
mailing list