test-lib.sh/test_decode_color(): use octal not hex in awk script
POSIX awk seems to explicitly not support hexadecimal escape sequences. From http://pubs.opengroup.org/onlinepubs/009695399/: Regular expressions in awk have been extended somewhat... One sequence that is not supported is hexadecimal value escapes beginning with '\x'. This affects the awk on IRIX 6.5, and causes t4015.56 to fail. Use octal instead. Signed-off-by: Brandon Casey <casey@nrlssc.navy.mil> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Brandon Casey committed
Dec 22, 2010 at 15:58 UTC
c2ed29b49b557b7bba8be147551cdd6e22fd743b
1 file changed
+1
-1
t/test-lib.sh
+1
-1
@@ -260,7 +260,7 @@ test_decode_color () {
260
if (n == 47) return "BWHITE";
261
}
262
{
263
- while (match($0, /\x1b\[[0-9;]*m/) != 0) {
263
+ while (match($0, /\033\[[0-9;]*m/) != 0) {
264
printf "%s<", substr($0, 1, RSTART-1);
265
codes = substr($0, RSTART+2, RLENGTH-3);
266
if (length(codes) == 0)