Skip to content

Commit fa9d348

Browse files
chressiespearce
authored andcommitted
git-am: force egrep to use correct characters set
According to egrep(1) the US-ASCII table is used when LC_ALL=C is set. We do not rely here on the LC_ALL value we get from the environment. Signed-off-by: Christian Himpel <[email protected]> Signed-off-by: Shawn O. Pearce <[email protected]>
1 parent 6900d75 commit fa9d348

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

git-am.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -205,7 +205,7 @@ check_patch_format () {
205205
# and see if it looks like that they all begin with the
206206
# header field names...
207207
sed -n -e '/^$/q' -e '/^[ ]/d' -e p "$1" |
208-
egrep -v '^[!-9;-~]+:' >/dev/null ||
208+
LC_ALL=C egrep -v '^[!-9;-~]+:' >/dev/null ||
209209
patch_format=mbox
210210
fi
211211
} < "$1" || clean_abort

0 commit comments

Comments
 (0)