Signed-off-by: Serge Hallyn <serge.hal...@ubuntu.com> --- src/lxc/cgmanager.c | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-)
diff --git a/src/lxc/cgmanager.c b/src/lxc/cgmanager.c index 92745dc..53a1802 100644 --- a/src/lxc/cgmanager.c +++ b/src/lxc/cgmanager.c @@ -130,10 +130,15 @@ struct cgm_data { char *cgroup_path; }; -void cgmanager_remove_cgroup(const char *subsystem, const char *path) +#define CG_REMOVE_RECURSIVE 1 +void cgmanager_remove_cgroup(const char *controller, const char *path) { - // TODO implement - WARN("%s: not yet implemented", __func__); + int existed; + if ( cgmanager_remove_sync(NULL, cgroup_manager, controller, + path, CG_REMOVE_RECURSIVE, &existed) != 0) + ERROR("Error removing %s:%s", controller, path); + if (!existed) + INFO("cgroup removal attempt: %s:%s did not exist"); } static void cgm_destroy(struct lxc_handler *handler) -- 1.8.5.2 _______________________________________________ lxc-devel mailing list lxc-devel@lists.linuxcontainers.org http://lists.linuxcontainers.org/listinfo/lxc-devel