.
This commit is contained in:
@@ -76,6 +76,8 @@ def parse_iwlist(iwlist_output, current_sid):
|
||||
if line.find("ESSID:") != -1:
|
||||
if line.partition("ESSID:")[2].strip('"') != "":
|
||||
cell["SSID"] = line.partition("ESSID:")[2].strip('"')
|
||||
else:
|
||||
cell["SSID"] = "!***!"
|
||||
if cell["SSID"] == current_sid:
|
||||
cell["Connected"] = "Yes"
|
||||
else:
|
||||
@@ -92,6 +94,8 @@ def parse_iwlist(iwlist_output, current_sid):
|
||||
except:
|
||||
cells = []
|
||||
|
||||
cells = [cell for cell in cells if cell["SSID"] != "!***!"]
|
||||
|
||||
return cells
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user