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

Bug#36552: gratuitous introduction of bashisms in devpts.sh



Package: libc6
Version: 2.1.1-1

This is the diff between devpts.sh from 2.1.1-0.2 and 2.1.1-1:

--- /etc/init.d/devpts.sh       Wed Apr  7 18:29:44 1999
+++ /etc/init.d/devpts.sh.dpkg-dist     Tue Apr 20 20:03:15 1999
@@ -8,11 +8,11 @@
     2.1.1[123]* | 2.2* | 2.3*)
        if grep devpts /proc/filesystems > /dev/null 2>&1
        then
-               if [ ! -c /dev/ptmx ]; then
+               if ! [ -c /dev/ptmx ]; then
                    mknod /dev/ptmx c 5 2
                    chmod 666 /dev/ptmx
                fi
-               if [ ! -d /dev/pts ]; then
+               if ! [ -d /dev/pts ]; then
                    mkdir /dev/pts
                    chmod 755 /dev/pts
                fi

The change makes absolutely no difference in the semantics of the
script AFAICT, but "if ! ..." is a bash extension which should not be
used in init scripts.  What was wrong with the old version?

zw


Reply to: