summaryrefslogtreecommitdiff
path: root/git/cmd.py
diff options
context:
space:
mode:
Diffstat (limited to 'git/cmd.py')
-rw-r--r--git/cmd.py5
1 files changed, 4 insertions, 1 deletions
diff --git a/git/cmd.py b/git/cmd.py
index b3274dd8..5323a63c 100644
--- a/git/cmd.py
+++ b/git/cmd.py
@@ -380,7 +380,10 @@ class Git(LazyMixin):
# END handle debug printing
if with_exceptions and status != 0:
- raise GitCommandError(command, status, stderr_value)
+ if with_extended_output:
+ raise GitCommandError(command, status, stderr_value, stdout_value)
+ else:
+ raise GitCommandError(command, status, stderr_value)
# Allow access to the command's status code
if with_extended_output: