]> git.ipfire.org Git - thirdparty/systemd.git/commitdiff
coredumpctl: show container hostame
authorZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>
Thu, 4 Mar 2021 00:09:42 +0000 (01:09 +0100)
committerYu Watanabe <watanabe.yu+github@gmail.com>
Thu, 4 Mar 2021 06:51:59 +0000 (15:51 +0900)
Fixes #18321. I don't see any point in showing the hostname in
_HOSTNAME: it's either the same as COREDUMP_HOSTNAME or irrelevant.

src/coredump/coredumpctl.c

index 5364169c4ff904a8036057b46b404995dabd6d65..9b09f86989314ec09660bd79c0925cbf221c92a5 100644 (file)
@@ -563,6 +563,7 @@ static int print_info(FILE *file, sd_journal *j, bool need_space) {
                 RETRIEVE(d, l, "COREDUMP_EXE", exe);
                 RETRIEVE(d, l, "COREDUMP_COMM", comm);
                 RETRIEVE(d, l, "COREDUMP_CMDLINE", cmdline);
+                RETRIEVE(d, l, "COREDUMP_HOSTNAME", hostname);
                 RETRIEVE(d, l, "COREDUMP_UNIT", unit);
                 RETRIEVE(d, l, "COREDUMP_USER_UNIT", user_unit);
                 RETRIEVE(d, l, "COREDUMP_SESSION", session);
@@ -575,7 +576,6 @@ static int print_info(FILE *file, sd_journal *j, bool need_space) {
                 RETRIEVE(d, l, "COREDUMP", coredump);
                 RETRIEVE(d, l, "_BOOT_ID", boot_id);
                 RETRIEVE(d, l, "_MACHINE_ID", machine_id);
-                RETRIEVE(d, l, "_HOSTNAME", hostname);
                 RETRIEVE(d, l, "MESSAGE", message);
         }