mirror of
https://github.com/nmap/nmap.git
synced 2025-12-07 05:01:29 +00:00
Merge #2088: Update Zenmap to Python 3 and PyGObject
Note: Ndiff build will be broken until subsequent changes are made. Deprecation warnings will need to be addressed in future changes. Closes #2088
This commit is contained in:
@@ -1,5 +1,4 @@
|
||||
#!/usr/bin/env python
|
||||
# -*- coding: utf-8 -*-
|
||||
#!/usr/bin/env python3
|
||||
|
||||
# ***********************IMPORTANT NMAP LICENSE TERMS************************
|
||||
# * *
|
||||
@@ -73,7 +72,7 @@ import zenmapCore.I18N # lgtm[py/unused-import]
|
||||
|
||||
try:
|
||||
import subprocess
|
||||
except ImportError, e:
|
||||
except ImportError as e:
|
||||
raise ImportError(str(e) + ".\n" + _("Python 2.4 or later is required."))
|
||||
|
||||
import zenmapCore.Paths
|
||||
@@ -183,7 +182,7 @@ class NmapCommand(object):
|
||||
if self.xml_is_temp:
|
||||
try:
|
||||
os.remove(self.xml_output_filename)
|
||||
except OSError, e:
|
||||
except OSError as e:
|
||||
if e.errno != errno.ENOENT:
|
||||
raise
|
||||
|
||||
|
||||
Reference in New Issue
Block a user