From 6b55ce0ed389b8a2ea0adee662adb59ddfe4c98d Mon Sep 17 00:00:00 2001 From: Christian Brauner Date: Tue, 2 Feb 2021 22:22:53 +0100 Subject: [PATCH] cgroups: return ENOCGROUP2 from cgroup_attach() Signed-off-by: Christian Brauner --- src/lxc/cgroups/cgfsng.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/lxc/cgroups/cgfsng.c b/src/lxc/cgroups/cgfsng.c index 498c2d819..c05e47906 100644 --- a/src/lxc/cgroups/cgfsng.c +++ b/src/lxc/cgroups/cgfsng.c @@ -3470,7 +3470,7 @@ int cgroup_attach(const struct lxc_conf *conf, const char *name, unified_fd = lxc_cmd_get_cgroup2_fd(name, lxcpath); if (unified_fd < 0) - return ret_errno(EBADF); + return ret_errno(ENOCGROUP2); if (!lxc_list_empty(&conf->id_map)) { struct userns_exec_unified_attach_data args = { -- 2.47.2