From a21aeccad0b0bbf28bb49810979dc1277d244f36 Mon Sep 17 00:00:00 2001 From: Cas Cremers Date: Sun, 26 Dec 2010 23:09:30 +0100 Subject: [PATCH] Fix caching discrepancy when relying on Scyther default options. --- gui/test-mpa.py | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/gui/test-mpa.py b/gui/test-mpa.py index 7ea2904..e11c9d1 100755 --- a/gui/test-mpa.py +++ b/gui/test-mpa.py @@ -178,6 +178,15 @@ def MyScyther(protocollist,filt=None,options=[]): # Standard opts = OPTS.defoptarray + options + # Cover for caching issue where no --match= option is given (default to 0) + matchfound = False + for opt in opts: + if opt.startswith("--match="): + matchfound = True + break + if not matchfound: + opts.append("--match=0") + # Adding other command-line parameters (i.e. with arguments) opts.append("-T %i" % (int(OPTS.timeout))) opts.append("--max-runs=%i" % (int(OPTS.maxruns)))