chiark
/
gitweb
/
~ianmdlvl
/
elogind.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
57ccf90
)
journalctl: don't choke on entries with no MESSAGE= field
author
Lennart Poettering
<lennart@poettering.net>
Tue, 18 Sep 2012 09:12:31 +0000
(11:12 +0200)
committer
Lennart Poettering
<lennart@poettering.net>
Tue, 18 Sep 2012 09:12:31 +0000
(11:12 +0200)
https://bugs.freedesktop.org/show_bug.cgi?id=50177
src/shared/logs-show.c
patch
|
blob
|
history
diff --git
a/src/shared/logs-show.c
b/src/shared/logs-show.c
index d60e5e53081c3cdacf828dc6562ef8837f2a9390..2ddff15bdb8e80a7522736a385056b3e7ed51496 100644
(file)
--- a/
src/shared/logs-show.c
+++ b/
src/shared/logs-show.c
@@
-536,6
+536,10
@@
static int output_cat(sd_journal *j, OutputMode mode, unsigned line,
r = sd_journal_get_data(j, "MESSAGE", &data, &l);
if (r < 0) {
+ /* An entry without MESSAGE=? */
+ if (r == -ENOENT)
+ return 0;
+
log_error("Failed to get data: %s", strerror(-r));
return r;
}