mirror of
https://github.com/sqlmapproject/sqlmap.git
synced 2025-12-06 20:51:31 +00:00
Proper patch for an Issue #591
This commit is contained in:
@@ -173,6 +173,9 @@ class Task(object):
|
|||||||
else:
|
else:
|
||||||
return None
|
return None
|
||||||
|
|
||||||
|
def engine_process(self):
|
||||||
|
return self.process
|
||||||
|
|
||||||
def engine_kill(self):
|
def engine_kill(self):
|
||||||
if self.process:
|
if self.process:
|
||||||
return self.process.kill()
|
return self.process.kill()
|
||||||
@@ -512,7 +515,7 @@ def scan_status(taskid):
|
|||||||
logger.warning("[%s] Invalid task ID provided to scan_status()" % taskid)
|
logger.warning("[%s] Invalid task ID provided to scan_status()" % taskid)
|
||||||
return jsonize({"success": False, "message": "Invalid task ID"})
|
return jsonize({"success": False, "message": "Invalid task ID"})
|
||||||
|
|
||||||
if DataStore.tasks[taskid].engine_get_returncode() is None:
|
if DataStore.tasks[taskid].engine_process() is None:
|
||||||
status = "not running"
|
status = "not running"
|
||||||
else:
|
else:
|
||||||
status = "terminated" if DataStore.tasks[taskid].engine_has_terminated() is True else "running"
|
status = "terminated" if DataStore.tasks[taskid].engine_has_terminated() is True else "running"
|
||||||
|
|||||||
Reference in New Issue
Block a user