diff options
-rwxr-xr-x | contrib/jail_prober.py | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/contrib/jail_prober.py b/contrib/jail_prober.py index 892e28f79..dad790b57 100755 --- a/contrib/jail_prober.py +++ b/contrib/jail_prober.py | |||
@@ -111,17 +111,22 @@ def run_firejail(program, allArgs): | |||
111 | """ | 111 | """ |
112 | goodArgs = ['firejail', '--noprofile', program] | 112 | goodArgs = ['firejail', '--noprofile', program] |
113 | badArgs = [] | 113 | badArgs = [] |
114 | allArgs.insert(0,"") | ||
114 | print('Attempting to run %s in Firejail' % program) | 115 | print('Attempting to run %s in Firejail' % program) |
115 | for arg in allArgs: | 116 | for arg in allArgs: |
116 | print('Running with', arg) | 117 | if arg: |
118 | print('Running with', arg) | ||
119 | else: | ||
120 | print('Running without profile') | ||
117 | #We are adding the argument in a copy of the actual list to avoid modify it now. | 121 | #We are adding the argument in a copy of the actual list to avoid modify it now. |
118 | myargs=goodArgs.copy() | 122 | myargs=goodArgs.copy() |
119 | myargs.insert(-1,arg) | 123 | if arg: |
124 | myargs.insert(-1,arg) | ||
120 | subprocess.call(myargs) | 125 | subprocess.call(myargs) |
121 | ans = input('Did %s run correctly? [y]/n ' % program) | 126 | ans = input('Did %s run correctly? [y]/n ' % program) |
122 | if ans in ['n', 'N']: | 127 | if ans in ['n', 'N']: |
123 | badArgs.append(arg) | 128 | badArgs.append(arg) |
124 | else: | 129 | elif arg: |
125 | goodArgs.insert(-1, arg) | 130 | goodArgs.insert(-1, arg) |
126 | print('\n') | 131 | print('\n') |
127 | # Don't include 'firejail', '--noprofile', or program name in arguments | 132 | # Don't include 'firejail', '--noprofile', or program name in arguments |