chiark
/
gitweb
/
~ianmdlvl
/
elogind.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
[2/5] Apply missing fixes from upstream
[elogind.git]
/
src
/
shared
/
cgroup-show.c
diff --git
a/src/shared/cgroup-show.c
b/src/shared/cgroup-show.c
index 530e6f2501c40bc6f5db2ab8611dc8ef4a29d6f2..4b038452fa80d84a274d6db6ca40e3d2225099a7 100644
(file)
--- a/
src/shared/cgroup-show.c
+++ b/
src/shared/cgroup-show.c
@@
-26,6
+26,7
@@
#include "util.h"
#include "formats-util.h"
#include "util.h"
#include "formats-util.h"
+#include "process-util.h"
#include "macro.h"
#include "path-util.h"
#include "cgroup-util.h"
#include "macro.h"
#include "path-util.h"
#include "cgroup-util.h"
@@
-151,7
+152,7
@@
int show_cgroup_by_path(const char *path, const char *prefix, unsigned n_columns
if (!k)
return -ENOMEM;
if (!k)
return -ENOMEM;
- if (!(flags & OUTPUT_SHOW_ALL) && cg_is_empty_recursive(NULL, k
, false
) > 0)
+ if (!(flags & OUTPUT_SHOW_ALL) && cg_is_empty_recursive(NULL, k) > 0)
continue;
if (!shown_pids) {
continue;
if (!shown_pids) {
@@
-160,8
+161,7
@@
int show_cgroup_by_path(const char *path, const char *prefix, unsigned n_columns
}
if (last) {
}
if (last) {
- printf("%s%s%s\n", prefix, draw_special_char(DRAW_TREE_BRANCH),
- basename(last));
+ printf("%s%s%s\n", prefix, draw_special_char(DRAW_TREE_BRANCH), cg_unescape(basename(last)));
if (!p1) {
p1 = strappend(prefix, draw_special_char(DRAW_TREE_VERTICAL));
if (!p1) {
p1 = strappend(prefix, draw_special_char(DRAW_TREE_VERTICAL));
@@
-184,8
+184,7
@@
int show_cgroup_by_path(const char *path, const char *prefix, unsigned n_columns
show_cgroup_one_by_path(path, prefix, n_columns, !!last, kernel_threads, flags);
if (last) {
show_cgroup_one_by_path(path, prefix, n_columns, !!last, kernel_threads, flags);
if (last) {
- printf("%s%s%s\n", prefix, draw_special_char(DRAW_TREE_RIGHT),
- basename(last));
+ printf("%s%s%s\n", prefix, draw_special_char(DRAW_TREE_RIGHT), cg_unescape(basename(last)));
if (!p2) {
p2 = strappend(prefix, " ");
if (!p2) {
p2 = strappend(prefix, " ");