diff options
author | Ian Moffett <ian@osmora.org> | 2024-05-25 17:51:54 -0400 |
---|---|---|
committer | Ian Moffett <ian@osmora.org> | 2024-05-25 17:51:54 -0400 |
commit | bd93d4966c5d78cb4ee2ab84d32890ea1ca77d53 (patch) | |
tree | bb8dc5e2a967679f288c3deed81a56af9a60f0c6 /sys/include/vm/obj.h | |
parent | 32f395140a653e5c7e3e114faeb7314e223f0eea (diff) |
kernel: vm: Make vmobj ref start at zero
Signed-off-by: Ian Moffett <ian@osmora.org>
Diffstat (limited to 'sys/include/vm/obj.h')
-rw-r--r-- | sys/include/vm/obj.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/sys/include/vm/obj.h b/sys/include/vm/obj.h index e4258ac..6e24516 100644 --- a/sys/include/vm/obj.h +++ b/sys/include/vm/obj.h @@ -49,7 +49,7 @@ struct vm_object { #define vm_object_ref(OBJPTR) (++(OBJPTR)->ref) #define vm_object_unref(OBJPTR) do { \ - if ((OBJPTR)->ref > 1) { \ + if ((OBJPTR)->ref > 0) { \ --(OBJPTR)->ref; \ } \ } while (0); |