File tree Expand file tree Collapse file tree 1 file changed +1
-12
lines changed Expand file tree Collapse file tree 1 file changed +1
-12
lines changed Original file line number Diff line number Diff line change @@ -169,18 +169,7 @@ cgroup_util_read_cgroup_memory_limit() {
169
169
[[ -n ${CGROUP_UTIL_VERBOSE-} ]] && echo " Reading cgroup v${controller_version} limit from '${location} '" >&2
170
170
171
171
local limit
172
- case " $controller_version " in
173
- 1)
174
- limit=$( cgroup_util_read_cgroupv1_memory_limit " $location " ) || return
175
- ;;
176
- 2)
177
- limit=$( cgroup_util_read_cgroupv2_memory_limit " $location " ) || return
178
- ;;
179
- * )
180
- echo " Internal error: invalid cgroup controller version '${controller_version} '" >&2
181
- return 1
182
- ;;
183
- esac
172
+ limit=$( cgroup_util_read_cgroupv" $controller_version " _memory_limit " $location " ) || return
184
173
185
174
if (( maximum > 0 && limit <= maximum )) ; then
186
175
echo " $limit "
You can’t perform that action at this time.
0 commit comments