summaryrefslogtreecommitdiff
path: root/usr.sbin/vmd/config.c
diff options
context:
space:
mode:
Diffstat (limited to 'usr.sbin/vmd/config.c')
-rw-r--r--usr.sbin/vmd/config.c15
1 files changed, 1 insertions, 14 deletions
diff --git a/usr.sbin/vmd/config.c b/usr.sbin/vmd/config.c
index 374d7de6629..c955212c6df 100644
--- a/usr.sbin/vmd/config.c
+++ b/usr.sbin/vmd/config.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: config.c,v 1.65 2022/05/08 14:44:54 dv Exp $ */
+/* $OpenBSD: config.c,v 1.66 2022/10/31 14:02:11 dv Exp $ */
/*
* Copyright (c) 2015 Reyk Floeter <reyk@openbsd.org>
@@ -98,12 +98,6 @@ config_init(struct vmd *env)
return (-1);
TAILQ_INIT(env->vmd_switches);
}
- if (what & CONFIG_USERS) {
- if ((env->vmd_users = calloc(1,
- sizeof(*env->vmd_users))) == NULL)
- return (-1);
- TAILQ_INIT(env->vmd_users);
- }
return (0);
}
@@ -238,13 +232,6 @@ config_setvm(struct privsep *ps, struct vmd_vm *vm, uint32_t peerid, uid_t uid)
return (EALREADY);
}
- /* increase the user reference counter and check user limits */
- if (vm->vm_user != NULL && user_get(vm->vm_user->usr_id.uid) != NULL) {
- user_inc(vcp, vm->vm_user, 1);
- if (user_checklimit(vm->vm_user, vcp) == -1)
- return (EPERM);
- }
-
/*
* Rate-limit the VM so that it cannot restart in a loop:
* if the VM restarts after less than VM_START_RATE_SEC seconds,