Catch Zenmap's MemoryError (caused by large Nmap Output) and provide the user a more useful error message so that we get less of the out-of-memory "crash reports"

This commit is contained in:
jay 2014-07-01 16:53:10 +00:00
parent 0066d3b24e
commit 2b30085d90
4 changed files with 57 additions and 15 deletions

View file

@ -654,7 +654,10 @@ class ScanInterface(HIGVBox):
warn_dialog.destroy()
parsed.set_xml_is_temp(command.xml_is_temp)
self.collect_umit_info(command, parsed)
parsed.nmap_output = command.get_output()
try:
parsed.nmap_output = command.get_output()
except MemoryError:
self.scan_result.scan_result_notebook.nmap_output.nmap_output.show_large_output_message(command)
self.update_ui()
self.scans_store.finish_running_scan(command, parsed)