tools: Drop duplicate raise_on_error argument
authorSimon Glass <sjg@chromium.org>
Mon, 8 Jul 2019 19:18:23 +0000 (13:18 -0600)
committerSimon Glass <sjg@chromium.org>
Wed, 24 Jul 2019 03:27:57 +0000 (20:27 -0700)
If kwargs contains raise_on_error then this function generates an error
due to a duplicate argument. Fix this.

Signed-off-by: Simon Glass <sjg@chromium.org>
tools/patman/command.py

index 14edcdaffd29cdc566ea8c70865443dac50170b3..16299f3f5be8bd203364d4fbf98733a0f7f3a375 100644 (file)
@@ -108,8 +108,8 @@ def RunPipe(pipe_list, infile=None, outfile=None,
     return result
 
 def Output(*cmd, **kwargs):
-    raise_on_error = kwargs.get('raise_on_error', True)
-    return RunPipe([cmd], capture=True, raise_on_error=raise_on_error).stdout
+    kwargs['raise_on_error'] = kwargs.get('raise_on_error', True)
+    return RunPipe([cmd], capture=True, **kwargs).stdout
 
 def OutputOneLine(*cmd, **kwargs):
     raise_on_error = kwargs.pop('raise_on_error', True)