mirror of
https://github.com/nmap/nmap.git
synced 2026-08-04 14:49:29 +00:00
When ndiff gets a command-line option it doesn't understand, print just the
exception message rather than the whole exception tuple. This changes
./ndiff: ('option --foo not recognized', 'foo')
to
./ndiff: option --foo not recognized
This commit is contained in:
parent
3868ca873e
commit
4db82f9351
1 changed files with 1 additions and 1 deletions
|
|
@ -689,7 +689,7 @@ def main():
|
|||
try:
|
||||
opts, input_filenames = getopt.gnu_getopt(sys.argv[1:], "hv", ["help", "text", "verbose", "xml"])
|
||||
except getopt.GetoptError, e:
|
||||
print >> sys.stderr, u"%s: %s" % (sys.argv[0], unicode(e))
|
||||
print >> sys.stderr, u"%s: %s" % (sys.argv[0], e.msg)
|
||||
sys.exit(1)
|
||||
for o, a in opts:
|
||||
if o == "-h" or o == "--help":
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue