Skip to content

Commit ae18930

Browse files
committed
update: initialize the rt_scheduler only on cgroupv1
5bdd930 introduced the regression. Closes: #1180 Signed-off-by: Giuseppe Scrivano <[email protected]>
1 parent 3437b64 commit ae18930

File tree

1 file changed

+6
-3
lines changed

1 file changed

+6
-3
lines changed

src/libcrun/cgroup-systemd.c

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1138,9 +1138,12 @@ libcrun_update_resources_systemd (struct libcrun_cgroup_status *cgroup_status,
11381138
goto exit;
11391139
}
11401140

1141-
ret = setup_rt_runtime (resources, cgroup_status->path, err);
1142-
if (UNLIKELY (ret < 0))
1143-
goto exit;
1141+
if (cgroup_mode != CGROUP_MODE_UNIFIED)
1142+
{
1143+
ret = setup_rt_runtime (resources, cgroup_status->path, err);
1144+
if (UNLIKELY (ret < 0))
1145+
goto exit;
1146+
}
11441147

11451148
ret = 0;
11461149

0 commit comments

Comments
 (0)