mirror of
https://github.com/sqlmapproject/sqlmap.git
synced 2024-11-24 10:33:47 +03:00
Minor patch for too fast Ctrl-C(-ers)
This commit is contained in:
parent
24d95ab6b3
commit
849babaf8d
18
sqlmap.py
18
sqlmap.py
|
@ -111,7 +111,10 @@ def main():
|
|||
|
||||
except SqlmapUserQuitException:
|
||||
errMsg = "user quit"
|
||||
try:
|
||||
logger.error(errMsg)
|
||||
except KeyboardInterrupt:
|
||||
pass
|
||||
|
||||
except (SqlmapSilentQuitException, bdb.BdbQuit):
|
||||
pass
|
||||
|
@ -121,18 +124,30 @@ def main():
|
|||
|
||||
except SqlmapBaseException as ex:
|
||||
errMsg = getSafeExString(ex)
|
||||
try:
|
||||
logger.critical(errMsg)
|
||||
except KeyboardInterrupt:
|
||||
pass
|
||||
|
||||
raise SystemExit
|
||||
|
||||
except KeyboardInterrupt:
|
||||
print
|
||||
|
||||
errMsg = "user aborted"
|
||||
try:
|
||||
logger.error(errMsg)
|
||||
except KeyboardInterrupt:
|
||||
pass
|
||||
|
||||
except EOFError:
|
||||
print
|
||||
errMsg = "exit"
|
||||
|
||||
try:
|
||||
logger.error(errMsg)
|
||||
except KeyboardInterrupt:
|
||||
pass
|
||||
|
||||
except SystemExit:
|
||||
pass
|
||||
|
@ -142,6 +157,7 @@ def main():
|
|||
errMsg = unhandledExceptionMessage()
|
||||
excMsg = traceback.format_exc()
|
||||
|
||||
try:
|
||||
if any(_ in excMsg for _ in ("No space left", "Disk quota exceeded")):
|
||||
errMsg = "no space left on output device"
|
||||
logger.error(errMsg)
|
||||
|
@ -168,6 +184,8 @@ def main():
|
|||
kb.stickyLevel = logging.CRITICAL
|
||||
dataToStdout(excMsg)
|
||||
createGithubIssue(errMsg, excMsg)
|
||||
except KeyboardInterrupt:
|
||||
pass
|
||||
|
||||
finally:
|
||||
if conf.get("showTime"):
|
||||
|
|
Loading…
Reference in New Issue
Block a user