mirror of
https://github.com/vanhoefm/fragattacks.git
synced 2024-11-25 00:38:24 -05:00
tests: Use bytes in a few places
With python3 bytes are returned for stdout, so need to use b'' strings instead of normal strings. These are just a few places I ran into, almost certainly more places need it. Signed-off-by: Johannes Berg <johannes.berg@intel.com>
This commit is contained in:
parent
db294952bb
commit
4dd712bd36
@ -553,7 +553,7 @@ def run_ap_vht160_no_dfs(dev, apdev, channel, ht_capab):
|
|||||||
cmd = subprocess.Popen(["iw", "reg", "get"], stdout=subprocess.PIPE)
|
cmd = subprocess.Popen(["iw", "reg", "get"], stdout=subprocess.PIPE)
|
||||||
reg = cmd.stdout.readlines()
|
reg = cmd.stdout.readlines()
|
||||||
for r in reg:
|
for r in reg:
|
||||||
if "5490" in r and "DFS" in r:
|
if b"5490" in r and b"DFS" in r:
|
||||||
raise HwsimSkip("ZA regulatory rule did not have DFS requirement removed")
|
raise HwsimSkip("ZA regulatory rule did not have DFS requirement removed")
|
||||||
raise Exception("AP setup timed out")
|
raise Exception("AP setup timed out")
|
||||||
|
|
||||||
|
@ -623,7 +623,7 @@ def run_ap_he160_no_dfs(dev, apdev, channel, ht_capab):
|
|||||||
cmd = subprocess.Popen(["iw", "reg", "get"], stdout=subprocess.PIPE)
|
cmd = subprocess.Popen(["iw", "reg", "get"], stdout=subprocess.PIPE)
|
||||||
reg = cmd.stdout.readlines()
|
reg = cmd.stdout.readlines()
|
||||||
for r in reg:
|
for r in reg:
|
||||||
if "5490" in r and "DFS" in r:
|
if b"5490" in r and b"DFS" in r:
|
||||||
raise HwsimSkip("ZA regulatory rule did not have DFS requirement removed")
|
raise HwsimSkip("ZA regulatory rule did not have DFS requirement removed")
|
||||||
raise Exception("AP setup timed out")
|
raise Exception("AP setup timed out")
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user