Skip to content

Commit

Permalink
lxc-ls: list names with whitespaces in --active.
Browse files Browse the repository at this point in the history
Signed-off-by: Edênis Freindorfer Azevedo <[email protected]>
[ small fixes ]
Signed-off-by: Alexander Mikhalitsyn <[email protected]>
  • Loading branch information
denisfa authored and mihalicyn committed Apr 2, 2024
1 parent a85d91b commit 6157b3d
Showing 1 changed file with 4 additions and 6 deletions.
10 changes: 4 additions & 6 deletions src/lxc/lxccontainer.c
Original file line number Diff line number Diff line change
Expand Up @@ -5478,14 +5478,12 @@ int list_active_containers(const char *lxcpath, char ***nret,
return -1;

while (getline(&line, &len, f) != -1) {
char *p = strrchr(line, ' '), *p2;
if (!p)
continue;
p++;
char *p, *p2;

if (*p != 0x40)
p = strstr(line, " @");
if (!p)
continue;
p++;
p += 2;

is_hashed = false;

Expand Down

0 comments on commit 6157b3d

Please sign in to comment.