summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xgit-clone.sh11
-rwxr-xr-xgit-send-email.perl6
2 files changed, 11 insertions, 6 deletions
diff --git a/git-clone.sh b/git-clone.sh
index 68085a3225..9a160eea52 100755
--- a/git-clone.sh
+++ b/git-clone.sh
@@ -56,11 +56,12 @@ fi
http_fetch () {
# $1 = Remote, $2 = Local
- curl -nsfL $curl_extra_args "$1" >"$2" ||
- case $? in
- 126|127) exit ;;
- *) return $? ;;
- esac
+ curl -nsfL $curl_extra_args "$1" >"$2"
+ curl_exit_status=$?
+ case $curl_exit_status in
+ 126|127) exit ;;
+ *) return $curl_exit_status ;;
+ esac
}
clone_dumb_http () {
diff --git a/git-send-email.perl b/git-send-email.perl
index 1d6f466453..248d035088 100755
--- a/git-send-email.perl
+++ b/git-send-email.perl
@@ -580,7 +580,7 @@ sub send_message
$ccline = "\nCc: $cc";
}
my $sanitized_sender = sanitize_address($sender);
- make_message_id();
+ make_message_id() unless defined($message_id);
my $header = "From: $sanitized_sender
To: $to${ccline}
@@ -718,6 +718,9 @@ foreach my $t (@files) {
}
push @xh, $_;
}
+ elsif (/^Message-Id: (.*)/i) {
+ $message_id = $1;
+ }
elsif (!/^Date:\s/ && /^[-A-Za-z]+:\s+\S/) {
push @xh, $_;
}
@@ -805,6 +808,7 @@ foreach my $t (@files) {
$references = "$message_id";
}
}
+ $message_id = undef;
}
if ($compose) {