|
@@ -16,14 +16,15 @@ logger = logging.getLogger()
|
|
|
_tshark_filter_arg = '-Y'
|
|
|
|
|
|
def run_tshark(filename, filter, display=None):
|
|
|
+ global _tshark_filter_arg
|
|
|
+
|
|
|
# wait a bit to make it more likely for wlantest sniffer to have captured
|
|
|
# and written the results into a file that we can process here
|
|
|
time.sleep(1)
|
|
|
|
|
|
try:
|
|
|
arg = [ "tshark", "-r", filename,
|
|
|
- _tshark_filter_arg, "wlan.fc.type_subtype == 4",
|
|
|
- "-Tfields", ]
|
|
|
+ _tshark_filter_arg, filter ]
|
|
|
if display:
|
|
|
arg.append('-Tfields')
|
|
|
for d in display:
|