mirror of
https://github.com/sqlmapproject/sqlmap.git
synced 2026-08-04 14:55:40 +00:00
Struggling with Github Actions
This commit is contained in:
parent
6ce9e40a90
commit
954a8e6ee7
3 changed files with 16 additions and 2 deletions
|
|
@ -60,6 +60,7 @@ _conn = None
|
|||
_cursor = None
|
||||
_lock = None
|
||||
_server = None
|
||||
_alive = False
|
||||
|
||||
def init(quiet=False):
|
||||
global _conn
|
||||
|
|
@ -236,14 +237,18 @@ class ReqHandler(BaseHTTPRequestHandler):
|
|||
return
|
||||
|
||||
def run(address=LISTEN_ADDRESS, port=LISTEN_PORT):
|
||||
global _alive
|
||||
global _server
|
||||
try:
|
||||
_alive = True
|
||||
_server = ThreadingServer((address, port), ReqHandler)
|
||||
print("[i] running HTTP server at 'http://%s:%d'" % (address, port))
|
||||
_server.serve_forever()
|
||||
except KeyboardInterrupt:
|
||||
_server.socket.close()
|
||||
raise
|
||||
finally:
|
||||
_alive = False
|
||||
|
||||
if __name__ == "__main__":
|
||||
try:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue