]> granicus.if.org Git - procps-ng/commit
library: adapt readproc for the latest lxc conventions
authorJim Warner <james.warner@comcast.net>
Thu, 10 Jan 2019 06:00:00 +0000 (00:00 -0600)
committerCraig Small <csmall@enc.com.au>
Tue, 22 Jan 2019 11:46:53 +0000 (22:46 +1100)
commitf67127e7288879d54448ffbb63c7319835c02e91
treec77835d20bee39c7f23b0518f93a25b274ed113a
parentdbe12b54009bd27d7a2a2f0142fd166f893279ad
library: adapt readproc for the latest lxc conventions

The merge request shown below prompted (thankfully) an
examination of our lxc containers logic in readproc.c.

As it turns out, the lxc folks changed that eyecatcher
used to identify containers within a task cgroup file.

So this patch, with little extra cost, will enable the
libprocps lxc_containers() guy to handle both strings.

[ additionally, I was shocked to find lxc allows the ]
[ eyecatcher to be changed at ./configure time. such ]
[ a provision has always existed. unfortunately, the ]
[ changed value was only available to root, assuming ]
[ one wished to tackle that undocumented liblxc api. ]

Reference(s):
. what prompted lxc support reevaluation
https://gitlab.com/procps-ng/procps/merge_requests/82
. original lxc support introduced
commit 0557504f9cb84987f9d9038755404be017bdb7d1

Signed-off-by: Jim Warner <james.warner@comcast.net>
proc/readproc.c