Blame 0034-base-dracut-lib.sh-do-not-setdebug-if-not-in-initram.patch

Harald Hoyer adf00e
From 2b125c69cc80baae765a868992003ddd349a7ae9 Mon Sep 17 00:00:00 2001
Harald Hoyer adf00e
From: Harald Hoyer <harald@redhat.com>
Harald Hoyer adf00e
Date: Thu, 18 Apr 2013 12:54:30 +0200
Harald Hoyer adf00e
Subject: [PATCH] base/dracut-lib.sh: do not setdebug, if not in initramfs
Harald Hoyer adf00e
Harald Hoyer adf00e
---
Harald Hoyer adf00e
 modules.d/99base/dracut-lib.sh | 1 +
Harald Hoyer adf00e
 1 file changed, 1 insertion(+)
Harald Hoyer adf00e
Harald Hoyer adf00e
diff --git a/modules.d/99base/dracut-lib.sh b/modules.d/99base/dracut-lib.sh
Harald Hoyer adf00e
index 9f4b2d2..ae79a82 100755
Harald Hoyer adf00e
--- a/modules.d/99base/dracut-lib.sh
Harald Hoyer adf00e
+++ b/modules.d/99base/dracut-lib.sh
Harald Hoyer adf00e
@@ -325,6 +325,7 @@ splitsep() {
Harald Hoyer adf00e
 }
Harald Hoyer adf00e
 
Harald Hoyer adf00e
 setdebug() {
Harald Hoyer adf00e
+    [ -f /etc/initrd-release ] || return
Harald Hoyer adf00e
     if [ -z "$RD_DEBUG" ]; then
Harald Hoyer adf00e
         if [ -e /proc/cmdline ]; then
Harald Hoyer adf00e
             RD_DEBUG=no