chiark
/
gitweb
/
~ianmdlvl
/
elogind.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
journalctl,systemctl: fix tiny memleak
[elogind.git]
/
src
/
shared
/
logs-show.c
diff --git
a/src/shared/logs-show.c
b/src/shared/logs-show.c
index 8dc11bb7fd983cf98984d1c14402a526340c699f..ea4746879bf3d43b925a4832b115d91e4508c91b 100644
(file)
--- a/
src/shared/logs-show.c
+++ b/
src/shared/logs-show.c
@@
-1059,7
+1059,12
@@
int show_journal_by_unit(
if (r < 0)
return r;
if (r < 0)
return r;
- log_debug("Journal filter: %s", journal_make_match_string(j));
+ if (_unlikely_(log_get_max_level() >= LOG_PRI(LOG_DEBUG))) {
+ _cleanup_free_ char *filter;
+
+ filter = journal_make_match_string(j);
+ log_debug("Journal filter: %s", filter);
+ }
r = show_journal(f, j, mode, n_columns, not_before, how_many, flags);
if (r < 0)
r = show_journal(f, j, mode, n_columns, not_before, how_many, flags);
if (r < 0)