Escaping leading '.' in cgroup names

Escaping a leading '.' with '_' in the cgroup names

Signed-off-by: Daniel P. Berrange <berrange@redhat.com>
This commit is contained in:
Daniel P. Berrange 2013-05-03 20:56:50 +01:00
parent ea74c07636
commit 0ced83dcfb

View File

@ -1106,7 +1106,8 @@ static int virCgroupPartitionNeedsEscaping(const char *path)
if (STRPREFIX(path, "cgroup."))
return 1;
if (path[0] == '_')
if (path[0] == '_' ||
path[0] == '.')
return 1;
if (!(fp = fopen("/proc/cgroups", "r")))