Skip to content
Snippets Groups Projects
Commit 264c5a97 authored by Thibault Debatty's avatar Thibault Debatty
Browse files

check passwords file exists

parent e5f9f2d2
No related branches found
No related tags found
No related merge requests found
......@@ -156,8 +156,12 @@ def main():
parse_arguments()
if not validators.url(ARGS.url) :
print("URL " + ARGS.url + "is not valid!")
sys.exit(-1)
print("URL " + ARGS.url + " is not valid!")
sys.exit()
if not os.path.isfile(ARGS.passwords) :
print("Passwords file " + ARGS.passwords + " does not exist!")
sys.exit()
with open(ARGS.passwords, "r") as passwords_file:
......@@ -183,7 +187,7 @@ def main():
except KeyboardInterrupt:
# User interrupt the program with ctrl+c
print_safe("Stopping threads...")
executor.shutdown(wait=False, cancel_futures=True)
executor.shutdown(wait=True, cancel_futures=True)
sys.exit()
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment