Swap: support freebsd

This commit is contained in:
李通洲 committed 2022-10-26 17:43:08 +08:00
1 parent aca2c01c9e
commit 64b9f69fb1
1 file changed
+3 -1
+3 -1
View File
@@ -1,6 +1,8 @@
#include "swap.h"
#include "common/sysctl.h"
void ffDetectSwapImpl(FFMemoryStorage* swap)
{
ffStrbufAppendS(&swap->error, "Not implemented");
swap->bytesTotal = (uint64_t)ffSysctlGetInt64("vm.swap_total", 0);
swap->bytesUsed = (uint64_t)ffSysctlGetInt64("vm.swap_reserved", 0);
}