From: Philippe Seewer Date: Tue, 16 Jun 2009 16:05:45 +0000 (+0200) Subject: Add warn() function to log warnings but not die() X-Git-Tag: 0.1~42 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=9f10836d6304acb2f353db93e2b9003cd196ff0a;p=thirdparty%2Fdracut.git Add warn() function to log warnings but not die() --- diff --git a/modules.d/99base/dracut-lib b/modules.d/99base/dracut-lib index 9cd515b84..00c21bd40 100644 --- a/modules.d/99base/dracut-lib +++ b/modules.d/99base/dracut-lib @@ -27,6 +27,10 @@ die() { exit 1 } +warn() { + printf "<1>Warning: $1\n" > /dev/kmsg +} + check_occurances() { # Count the number of times the character $ch occurs in $str # Return 0 if the count matches the expected number, 1 otherwise