Remove unused imports and specific exception

This commit is contained in:
Moshe Kaplan 2019-03-03 16:49:40 -05:00 committed by GitHub
parent 2dcecdc1fa
commit c33c1043f5
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 8 additions and 7 deletions

View File

@ -7,17 +7,18 @@
# option) any later version. # option) any later version.
# #
import argparse
import asyncio
from colorama import init, Fore, Back, Style
from concurrent.futures import ProcessPoolExecutor, as_completed, FIRST_COMPLETED
import ipaddress
import os import os
import re import re
import sys
import socket import socket
import string import string
import sys import asyncio
import argparse
import ipaddress
from concurrent.futures import ProcessPoolExecutor, as_completed, FIRST_COMPLETED
import toml import toml
from colorama import Fore, Style
verbose = 0 verbose = 0
nmap = '' nmap = ''
@ -575,7 +576,7 @@ if __name__ == '__main__':
if target not in targets: if target not in targets:
targets.append(target) targets.append(target)
except: except socket.gaierror:
error(target + ' does not appear to be a valid IP address, IP range, or resolvable hostname.') error(target + ' does not appear to be a valid IP address, IP range, or resolvable hostname.')
errors = True errors = True