39 lines
962 B
Diff
39 lines
962 B
Diff
|
From 4fbccde50456f513d388cdfd858018cd889890dc Mon Sep 17 00:00:00 2001
|
||
|
From: Dusty Mabe <dusty@dustymabe.com>
|
||
|
Date: Wed, 14 Apr 2021 16:23:29 -0400
|
||
|
Subject: [PATCH] fix(dracut-logger.sh): double dash trigger unknown logger
|
||
|
warnings during run
|
||
|
|
||
|
There are a bunch of `logger: unknown facility name: --user` errors
|
||
|
during a run. This is because logger is getting passed something like:
|
||
|
|
||
|
```
|
||
|
logger -p --user.info
|
||
|
```
|
||
|
|
||
|
Where it should be something like:
|
||
|
|
||
|
```
|
||
|
logger -p user.info
|
||
|
```
|
||
|
---
|
||
|
dracut-logger.sh | 2 +-
|
||
|
1 file changed, 1 insertion(+), 1 deletion(-)
|
||
|
|
||
|
diff --git a/dracut-logger.sh b/dracut-logger.sh
|
||
|
index c36525d0..07389285 100755
|
||
|
--- a/dracut-logger.sh
|
||
|
+++ b/dracut-logger.sh
|
||
|
@@ -241,7 +241,7 @@ _lvl2char() {
|
||
|
# @retval 0 if @a lvl is correct.
|
||
|
# @result Echoes logger priority.
|
||
|
_lvl2syspri() {
|
||
|
- printf "%s" -- "$syslogfacility."
|
||
|
+ printf -- "%s" "$syslogfacility."
|
||
|
case "$1" in
|
||
|
1) echo crit;;
|
||
|
2) echo error;;
|
||
|
--
|
||
|
2.30.2
|
||
|
|