summaryrefslogtreecommitdiff
path: root/dracut-logger.sh
diff options
context:
space:
mode:
authorHarald Hoyer <harald@redhat.com>2012-06-22 15:35:09 +0200
committerHarald Hoyer <harald@redhat.com>2012-06-29 12:41:26 +0200
commitb47d7a5fd4b81aa93e1304d7ed843b3bef31a6d8 (patch)
tree9383ee2f5fae16b56a27499164dd91622356e807 /dracut-logger.sh
parent5d897c82b909b5b3050b9bfacee6ada1242c5a61 (diff)
downloaddracut-b47d7a5fd4b81aa93e1304d7ed843b3bef31a6d8.tar.gz
dracut-b47d7a5fd4b81aa93e1304d7ed843b3bef31a6d8.tar.bz2
dracut-b47d7a5fd4b81aa93e1304d7ed843b3bef31a6d8.zip
dracut-logger.sh: empty functions for log funcs, which are below level
Diffstat (limited to 'dracut-logger.sh')
-rwxr-xr-xdracut-logger.sh33
1 files changed, 33 insertions, 0 deletions
diff --git a/dracut-logger.sh b/dracut-logger.sh
index a78e18ee..dbe26eed 100755
--- a/dracut-logger.sh
+++ b/dracut-logger.sh
@@ -164,6 +164,39 @@ dlog_init() {
readonly maxloglvl=$maxloglvl_l
export maxloglvl
+
+ if (($stdloglvl < 6)) && (($kmsgloglvl < 6)) && (($fileloglvl < 6)); then
+ unset dtrace
+ dtrace() { :; };
+ fi
+
+ if (($stdloglvl < 5)) && (($kmsgloglvl < 5)) && (($fileloglvl < 5)); then
+ unset ddebug
+ ddebug() { :; };
+ fi
+
+ if (($stdloglvl < 4)) && (($kmsgloglvl < 4)) && (($fileloglvl < 4)); then
+ unset dinfo
+ dinfo() { :; };
+ fi
+
+ if (($stdloglvl < 3)) && (($kmsgloglvl < 3)) && (($fileloglvl < 3)); then
+ unset dwarn
+ dwarn() { :; };
+ unset dwarning
+ dwarning() { :; };
+ fi
+
+ if (($stdloglvl < 2)) && (($kmsgloglvl < 2)) && (($fileloglvl < 2)); then
+ unset derror
+ derror() { :; };
+ fi
+
+ if (($stdloglvl < 1)) && (($kmsgloglvl < 1)) && (($fileloglvl < 1)); then
+ unset dfatal
+ dfatal() { :; };
+ fi
+
[ -n "$errmsg" ] && derror "$errmsg"
return $ret