summaryrefslogtreecommitdiff
path: root/git-am.sh
diff options
context:
space:
mode:
authorDmitry V. Levin <ldv@altlinux.org>2013-01-14 20:59:33 (GMT)
committerJunio C Hamano <gitster@pobox.com>2013-01-18 20:37:39 (GMT)
commit5185b9707a768a0ad17de4765c7893f86f4c4a0e (patch)
tree3dbbd2c62403b777d6db1e56188d79f76aaa9d71 /git-am.sh
parent0cfd112032017ab68ed576f6bb5258452084ebf1 (diff)
downloadgit-5185b9707a768a0ad17de4765c7893f86f4c4a0e.zip
git-5185b9707a768a0ad17de4765c7893f86f4c4a0e.tar.gz
git-5185b9707a768a0ad17de4765c7893f86f4c4a0e.tar.bz2
am: invoke perl's strftime in C locale
We used to convert timestamps in metadata comment of Hg patch to mbox-looking Date: field using strftime, without making sure the resulting string is not translated. Always use C locale for this. Signed-off-by: Dmitry V. Levin <ldv@altlinux.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'git-am.sh')
-rwxr-xr-xgit-am.sh2
1 files changed, 1 insertions, 1 deletions
diff --git a/git-am.sh b/git-am.sh
index eaa8a11..c72d052 100755
--- a/git-am.sh
+++ b/git-am.sh
@@ -261,7 +261,7 @@ split_patches () {
# Since we cannot guarantee that the commit message is in
# git-friendly format, we put no Subject: line and just consume
# all of the message as the body
- perl -M'POSIX qw(strftime)' -ne 'BEGIN { $subject = 0 }
+ LANG=C LC_ALL=C perl -M'POSIX qw(strftime)' -ne 'BEGIN { $subject = 0 }
if ($subject) { print ; }
elsif (/^\# User /) { s/\# User/From:/ ; print ; }
elsif (/^\# Date /) {