blob: a756d047ef1d8c20baa6f1a5f89fa0bb097a12a1 [file] [log] [blame]
Patrick Williamsc124f4f2015-09-15 14:41:29 -05001Upstream-Status: Inappropriate [configuration]
2
3Signed-off-by: Xiaofeng Yan <xiaofeng.yan@windriver.com>
4Signed-off-by: Saul Wold <sgw@linux.intel.com>
5
6Index: initscripts-9.43/rc.d/init.d/functions
7===================================================================
8--- initscripts-9.43.orig/rc.d/init.d/functions
9+++ initscripts-9.43/rc.d/init.d/functions
10@@ -13,6 +13,7 @@ umask 022
11 PATH="/sbin:/usr/sbin:/bin:/usr/bin"
12 export PATH
13
14+
15 if [ $PPID -ne 1 -a -z "$SYSTEMCTL_SKIP_REDIRECT" ] && \
16 ( /bin/mountpoint -q /cgroup/systemd || /bin/mountpoint -q /sys/fs/cgroup/systemd ) ; then
17 case "$0" in
18@@ -54,7 +55,7 @@ systemctl_redirect () {
19 [ -z "${COLUMNS:-}" ] && COLUMNS=80
20
21 if [ -z "${CONSOLETYPE:-}" ]; then
22- if [ -c "/dev/stderr" -a -r "/dev/stderr" ]; then
23+ if [ -c "/dev/stderr" -a -r "/dev/stderr" -a -e /sbin/consoletype ]; then
24 CONSOLETYPE="$(/sbin/consoletype < /dev/stderr 2>/dev/null)"
25 else
26 CONSOLETYPE="serial"