1
0
mirror of https://github.com/nmap/nmap.git synced 2025-12-06 12:41:29 +00:00

Catch an exception that happens while aggregating a new scan.

This commit is contained in:
david
2012-06-21 00:56:55 +00:00
parent aca56d8f6e
commit feea11ed24

View File

@@ -578,7 +578,17 @@ There was an error while parsing the XML file generated from the scan:
parsed.unsaved = True
self.scan_result.refresh_nmap_output()
self.inventory.add_scan(parsed)
try:
self.inventory.add_scan(parsed)
except Exception, e:
warn_dialog = HIGAlertDialog(message_format = _("Cannot merge scan"),
secondary_text = _(u"""\
There was an error while merging the new scan's XML:
%s\
""") % str(e), type = gtk.MESSAGE_ERROR)
warn_dialog.run()
warn_dialog.destroy()
parsed.set_xml_is_temp(command.xml_is_temp)
self.collect_umit_info(command, parsed)
parsed.nmap_output = command.get_output()