]> git.pld-linux.org Git - packages/coreutils.git/commitdiff
- allow obsolete head/tail syntax if POSIXLY_CORRECT is not set
authorJakub Bogusz <qboosh@pld-linux.org>
Wed, 14 Jan 2004 14:03:25 +0000 (14:03 +0000)
committercvs2git <feedback@pld-linux.org>
Sun, 24 Jun 2012 12:13:13 +0000 (12:13 +0000)
Changed files:
    coreutils-noposix2.patch -> 1.1

coreutils-noposix2.patch [new file with mode: 0644]

diff --git a/coreutils-noposix2.patch b/coreutils-noposix2.patch
new file mode 100644 (file)
index 0000000..635bbca
--- /dev/null
@@ -0,0 +1,22 @@
+--- coreutils-5.0/src/head.c.orig      Tue Oct  1 10:47:44 2002
++++ coreutils-5.0/src/head.c   Wed Jan 14 14:54:24 2004
+@@ -343,7 +343,7 @@
+           }
+       }
+-      if (200112 <= posix2_version ())
++      if ((200112 <= posix2_version ()) && getenv("POSIXLY_CORRECT"))
+       {
+         error (0, 0, _("`-%s' option is obsolete; use `-%c %.*s%.*s%s'"),
+                n_string, count_lines ? 'n' : 'c',
+--- coreutils-5.0/src/tail.c.orig      Sat Dec 14 18:26:21 2002
++++ coreutils-5.0/src/tail.c   Wed Jan 14 14:55:59 2004
+@@ -1298,7 +1298,7 @@
+   if (argc < 2)
+     return 0;
+-  obsolete_usage = (posix2_version () < 200112);
++  obsolete_usage = ((posix2_version () < 200112) || !getenv("POSIXLY_CORRECT"));
+   /* If P starts with `+' and the POSIX version predates 1003.1-2001,
+      or if P starts with `-N' (where N is a digit), or `-l', then it
This page took 0.104082 seconds and 4 git commands to generate.