]> git.proxmox.com Git - mirror_lxcfs.git/commit
proc: Fix swap handling for cgroups v2 (zero limits)
authorAlex Hudspith <alex@hudspith.io>
Mon, 6 Nov 2023 09:17:38 +0000 (09:17 +0000)
committerAlexander Mikhalitsyn <aleksandr.mikhalitsyn@canonical.com>
Wed, 27 Mar 2024 12:39:23 +0000 (13:39 +0100)
commita6c309be27e266b310851ca101a1b08644b1d9d5
treee1229224ba3eb07ba3cb806c241bf25395aabc41
parentf496e62cdbeb01215af34fed266fc5a98d25feeb
proc: Fix swap handling for cgroups v2 (zero limits)

Since memory.swap.max = 0 is valid under v2, limits of 0 must not be
treated differently. Instead, use UINT64_MAX as the default limit. This aligns
with cgroups v1 behaviour anyway since 'limit_in_bytes' files contain a large
number for unspecified limits (2^63).

Resolves: #534
Signed-off-by: Alex Hudspith <alex@hudspith.io>
src/proc_fuse.c