Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/usr.bin/sed/TEST In test_error() use <& to duplicate input d...



details:   https://anonhg.NetBSD.org/src/rev/e6410436ea7e
branches:  trunk
changeset: 554396:e6410436ea7e
user:      uwe <uwe%NetBSD.org@localhost>
date:      Mon Oct 27 20:09:49 2003 +0000

description:
In test_error() use <& to duplicate input descriptors,
correct the order of descriptors in redirection that saves stdin.

diffstat:

 usr.bin/sed/TEST/sed.test |  8 ++++----
 1 files changed, 4 insertions(+), 4 deletions(-)

diffs (37 lines):

diff -r 8162f5a86622 -r e6410436ea7e usr.bin/sed/TEST/sed.test
--- a/usr.bin/sed/TEST/sed.test Mon Oct 27 19:46:14 2003 +0000
+++ b/usr.bin/sed/TEST/sed.test Mon Oct 27 20:09:49 2003 +0000
@@ -1,5 +1,5 @@
 #!/bin/sh -
-#      $NetBSD: sed.test,v 1.3 1997/01/09 20:21:37 tls Exp $
+#      $NetBSD: sed.test,v 1.4 2003/10/27 20:09:49 uwe Exp $
 #
 # Copyright (c) 1992 Diomidis Spinellis.
 # Copyright (c) 1992, 1993
@@ -34,7 +34,7 @@
 # SUCH DAMAGE.
 #
 #      from: @(#)sed.test      8.1 (Berkeley) 6/6/93
-#      $NetBSD: sed.test,v 1.3 1997/01/09 20:21:37 tls Exp $
+#      $NetBSD: sed.test,v 1.4 2003/10/27 20:09:49 uwe Exp $
 #
 
 # sed Regression Tests
@@ -513,7 +513,7 @@
 
 test_error()
 {
-       exec 0>&3 4>&1 5>&2
+       exec 3<&0 4>&1 5>&2
        exec 0</dev/null
        exec 2>&1
        set -x
@@ -548,7 +548,7 @@
        $TEST '!' && exit 1
        $TEST supercalifrangolisticexprialidociussupercalifrangolisticexcius
        set +x
-       exec 0>&3 1>&4 2>&5
+       exec 0<&3 1>&4 2>&5
 }
 
 main



Home | Main Index | Thread Index | Old Index