diff --git a/man/coredumpctl.xml b/man/coredumpctl.xml index 68ba6dc9f2..6ceed41b05 100644 --- a/man/coredumpctl.xml +++ b/man/coredumpctl.xml @@ -362,7 +362,7 @@ Fri … 552351 1000 1000 SIGSEGV present /usr/lib64/firefox/firefox 28.7M GID: 1000 (user) Signal: 11 (SEGV) Timestamp: Mon 2021-01-01 00:00:01 CET (20s ago) - Command Line: bash -c kill -SEGV $$ + Command Line: bash -c $'kill -SEGV $$' Executable: /usr/bin/bash Control Group: /user.slice/user-1000.slice/… Unit: user@1000.service diff --git a/src/coredump/coredump.c b/src/coredump/coredump.c index 2fb2404500..a16be3c448 100644 --- a/src/coredump/coredump.c +++ b/src/coredump/coredump.c @@ -665,7 +665,7 @@ static int get_process_container_parent_cmdline(pid_t pid, char** cmdline) { if (r < 0) return r; - r = get_process_cmdline(container_pid, SIZE_MAX, 0, cmdline); + r = get_process_cmdline(container_pid, SIZE_MAX, PROCESS_CMDLINE_QUOTE_POSIX, cmdline); if (r < 0) return r; @@ -1115,7 +1115,7 @@ static int gather_pid_metadata(struct iovec_wrapper *iovw, Context *context) { if (sd_pid_get_slice(pid, &t) >= 0) (void) iovw_put_string_field_free(iovw, "COREDUMP_SLICE=", t); - if (get_process_cmdline(pid, SIZE_MAX, 0, &t) >= 0) + if (get_process_cmdline(pid, SIZE_MAX, PROCESS_CMDLINE_QUOTE_POSIX, &t) >= 0) (void) iovw_put_string_field_free(iovw, "COREDUMP_CMDLINE=", t); if (cg_pid_get_path_shifted(pid, NULL, &t) >= 0)