systemd/0001-pid1-more-informative-error-message-for-ignored-noti.patch

39 lines
1.4 KiB
Diff
Raw Normal View History

Accepting request 431464 from Base:System - Import a better fix from upstream for bsc#1001765 - Added: 0001-pid1-more-informative-error-message-for-ignored-noti.patch 0001-pid1-process-zero-length-notification-messages-again.patch - Updated (no code changes, only patch metadata) 0001-If-the-notification-message-length-is-0-ignore-the-m.patch 0001-pid1-don-t-return-any-error-in-manager_dispatch_noti.patch - Re add back "udev: don't require nsserv and fillup" Did this in the wrong project... it was a complicated day today ;) - Added 2 patches to fix bsc#1001765 0001-If-the-notification-message-length-is-0-ignore-the-m.patch 0001-pid1-don-t-return-any-error-in-manager_dispatch_noti.patch - Revert "udev: don't require nsserv and fillup" It's been judged too late for being part of SLE12 final release. Nevertheless it's part of Factory and will be reintroduced after the final release is out (ie through an update). - systemd-sysv-convert: make sure that /var/lib/systemd/sysv-convert/database is always initialized (bsc#982211) If "--save" command was used and the sysv init script wasn't enabled at all the database file wasn't created at all. This makes the subsequent call to "--apply" fail even though this should not considered as an error. - Added patches to fix journal with FSS protection enabled (bsc#1000435) 0001-journal-fix-HMAC-calculation-when-appending-a-data-o.patch 0001-journal-set-STATE_ARCHIVED-as-part-of-offlining-2740.patch OBS-URL: https://build.opensuse.org/request/show/431464 OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/systemd?expand=0&rev=241
2016-10-01 21:46:24 +00:00
From eb54b43fe31392c9f77505d8f9cd86d1f050b49d Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Zbigniew=20J=C4=99drzejewski-Szmek?= <zbyszek@in.waw.pl>
Date: Thu, 29 Sep 2016 16:07:41 +0200
Subject: [PATCH 1/1] pid1: more informative error message for ignored
notifications
It's probably easier to diagnose a bad notification message if the
contents are printed. But still, do anything only if debugging is on.
(cherry picked from commit a86b76753d7868c2d05f046f601bc7dc89fc2203)
---
src/core/manager.c | 10 ++++++++--
1 file changed, 8 insertions(+), 2 deletions(-)
diff --git a/src/core/manager.c b/src/core/manager.c
index 58d346e..0d0158a 100644
--- a/src/core/manager.c
+++ b/src/core/manager.c
@@ -1516,8 +1516,14 @@ static void manager_invoke_notify_message(Manager *m, Unit *u, pid_t pid, const
if (UNIT_VTABLE(u)->notify_message)
UNIT_VTABLE(u)->notify_message(u, pid, tags, fds);
- else
- log_unit_debug(u, "Got notification message for unit. Ignoring.");
+ else if (_unlikely_(log_get_max_level() >= LOG_DEBUG)) {
+ _cleanup_free_ char *x = NULL, *y = NULL;
+
+ x = cescape(buf);
+ if (x)
+ y = ellipsize(x, 20, 90);
+ log_unit_debug(u, "Got notification message \"%s\", ignoring.", strnull(y));
+ }
}
static int manager_dispatch_notify_fd(sd_event_source *source, int fd, uint32_t revents, void *userdata) {
--
2.10.0