summaryrefslogtreecommitdiff
path: root/dgit
diff options
context:
space:
mode:
Diffstat (limited to 'dgit')
-rwxr-xr-xdgit17
1 files changed, 7 insertions, 10 deletions
diff --git a/dgit b/dgit
index 497687a..5308386 100755
--- a/dgit
+++ b/dgit
@@ -1504,16 +1504,6 @@ sub cmd_rpush {
};
i_method "i_resp", $icmd, $iargs;
}
-
- my $pid = $i_child_pid;
- $i_child_pid = undef; # prevents killing some other process with same pid
- printdebug "waiting for remote child $pid...";
- my $got = waitpid $pid, 0;
- die $! unless $got == $pid;
- die "remote child failed $?" if $?;
-
- i_cleanup();
- exit 0;
}
sub i_resp_progress ($) {
@@ -1523,6 +1513,13 @@ sub i_resp_progress ($) {
}
sub i_resp_complete {
+ my $pid = $i_child_pid;
+ $i_child_pid = undef; # prevents killing some other process with same pid
+ printdebug "waiting for remote child $pid...";
+ my $got = waitpid $pid, 0;
+ die $! unless $got == $pid;
+ die "remote child failed $?" if $?;
+
i_cleanup();
exit 0;
}