summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xgit-add--interactive.perl1
1 files changed, 1 insertions, 0 deletions
diff --git a/git-add--interactive.perl b/git-add--interactive.perl
index 1fadd69f88..c7256741cc 100755
--- a/git-add--interactive.perl
+++ b/git-add--interactive.perl
@@ -1356,6 +1356,7 @@ sub patch_update_file {
$patch_mode_flavour{TARGET},
" [y,n,q,a,d,/$other,?]? ";
my $line = prompt_single_character;
+ last unless defined $line;
if ($line) {
if ($line =~ /^y/i) {
$hunk[$ix]{USE} = 1;