aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorThomas Deutschmann <whissi@gentoo.org>2021-03-13 18:08:40 +0100
committerThomas Deutschmann <whissi@gentoo.org>2021-03-14 20:33:34 +0100
commitbf26667ac4a906601eda8ce72cdd7058556bf387 (patch)
treef2f38679a023559823d48de3115163c440d1c91d
parentlinuxrc: Don't delete /linuxrc (diff)
downloadgenkernel-bf26667ac4a906601eda8ce72cdd7058556bf387.tar.gz
genkernel-bf26667ac4a906601eda8ce72cdd7058556bf387.tar.bz2
genkernel-bf26667ac4a906601eda8ce72cdd7058556bf387.zip
linuxrc: Reformat exec code
Signed-off-by: Thomas Deutschmann <whissi@gentoo.org>
-rw-r--r--defaults/linuxrc4
1 files changed, 2 insertions, 2 deletions
diff --git a/defaults/linuxrc b/defaults/linuxrc
index 1c051bc..f20d606 100644
--- a/defaults/linuxrc
+++ b/defaults/linuxrc
@@ -21,7 +21,7 @@
[ ! -e /dev/zero ] && mknod /dev/zero c 1 5
# Take control
-exec >${CONSOLE} <${CONSOLE} 2>&1
+exec 0<>${CONSOLE} 1<>${CONSOLE} 2<>${CONSOLE}
if [ "$$" != '1' ]
then
@@ -462,7 +462,7 @@ then
[ ! -c "${NEW_CONSOLE}" ] && NEW_CONSOLE="/dev/${NEW_CONSOLE}"
if [ -c "${NEW_CONSOLE}" ]
then
- exec >${NEW_CONSOLE} <${NEW_CONSOLE} 2>&1
+ exec 0<>${NEW_CONSOLE} 1<>${NEW_CONSOLE} 2<>${NEW_CONSOLE}
good_msg "Console switched from '${CONSOLE}' to '${NEW_CONSOLE}'!"
CONSOLE="${NEW_CONSOLE}"
else