From 7fcd134399a2d79f2ebe804653d1b7d2e500fb33 Mon Sep 17 00:00:00 2001 From: Lennart Poettering Date: Mon, 16 Oct 2023 13:16:55 +0200 Subject: [PATCH] namespace: add // FIXME comments on some suplicate logging @bluca thinks duplicate logging as a feature, hence simply mark these log messages as // FIXME, but don't bother. --- src/core/namespace.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/core/namespace.c b/src/core/namespace.c index 7d14a931446..273eb962b53 100644 --- a/src/core/namespace.c +++ b/src/core/namespace.c @@ -1361,7 +1361,7 @@ static int mount_image( if (r == -ENOENT && m->ignore) return 0; if (r == -ESTALE && host_os_release_id) - return log_error_errno(r, + return log_error_errno(r, // FIXME: this should not be logged ad LOG_ERR, as it will result in duplicate logging. "Failed to mount image %s, extension-release metadata does not match the lower layer's: ID=%s%s%s%s%s%s%s", mount_entry_source(m), host_os_release_id, @@ -1637,7 +1637,7 @@ static int apply_one_mount( q = make_mount_point_inode_from_path(what, mount_entry_path(m), 0755); if (q < 0) { - if (q != -EEXIST) + if (q != -EEXIST) // FIXME: this shouldn't be logged at LOG_WARNING, but be bubbled up, and logged there to avoid duplicate logging log_warning_errno(q, "Failed to create destination mount point node '%s', ignoring: %m", mount_entry_path(m)); } else @@ -1647,7 +1647,7 @@ static int apply_one_mount( if (try_again) r = mount_nofollow_verbose(LOG_DEBUG, what, mount_entry_path(m), NULL, MS_BIND|(rbind ? MS_REC : 0), NULL); if (r < 0) - return log_error_errno(r, "Failed to mount %s to %s: %m", what, mount_entry_path(m)); + return log_error_errno(r, "Failed to mount %s to %s: %m", what, mount_entry_path(m)); // FIXME: this should not be logged here, but be bubbled up, to avoid duplicate logging } log_debug("Successfully mounted %s to %s", what, mount_entry_path(m)); -- 2.47.3