From ac6e455f16099031f630cb5754f4594c6aeec950 Mon Sep 17 00:00:00 2001 From: Ben Gras Date: Tue, 22 Jun 2010 15:28:07 +0000 Subject: [PATCH] . make sed understand \t . install it in /bin, where minix rc expects it --- commands/sed/Makefile | 2 ++ commands/sed/compile.c | 4 ++++ 2 files changed, 6 insertions(+) diff --git a/commands/sed/Makefile b/commands/sed/Makefile index 53b7bf42e..0addb8171 100644 --- a/commands/sed/Makefile +++ b/commands/sed/Makefile @@ -6,4 +6,6 @@ PROG= sed SRCS= compile.c main.c misc.c process.c +BINDIR=/bin + .include diff --git a/commands/sed/compile.c b/commands/sed/compile.c index e41be0856..6c8aad65b 100644 --- a/commands/sed/compile.c +++ b/commands/sed/compile.c @@ -404,6 +404,10 @@ compile_delimited(char *p, char *d) *d++ = '\n'; p += 2; continue; + } else if (*p == '\\' && p[1] == 't') { + *d++ = '\t'; + p += 2; + continue; } else if (*p == '\\' && p[1] == '\\') *d++ = *p++; else if (*p == c) {