summaryrefslogtreecommitdiff
path: root/usr.sbin/vmctl/vmctl.c
diff options
context:
space:
mode:
authorkn <kn@cvs.openbsd.org>2019-12-15 14:37:00 +0000
committerkn <kn@cvs.openbsd.org>2019-12-15 14:37:00 +0000
commitd4574447dc202586e5ee6a50e8c90ad90ce7535b (patch)
treeff806241d040c46f067e161074559fa726b5a0ad /usr.sbin/vmctl/vmctl.c
parent47c49ba51fa8e3e2eb8b52edbb9db9a6116344ea (diff)
Explicitly print root user in status OWNER column
With "owner root:wheel" (any group) the status output prints ":wheel" only, presumably to emphasize that only group membership matters. Always print whatever is configured to be explicit and less confusing. OK jasper
Diffstat (limited to 'usr.sbin/vmctl/vmctl.c')
-rw-r--r--usr.sbin/vmctl/vmctl.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/usr.sbin/vmctl/vmctl.c b/usr.sbin/vmctl/vmctl.c
index 52f57268947..cafdbeecd51 100644
--- a/usr.sbin/vmctl/vmctl.c
+++ b/usr.sbin/vmctl/vmctl.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: vmctl.c,v 1.72 2019/12/12 03:53:38 pd Exp $ */
+/* $OpenBSD: vmctl.c,v 1.73 2019/12/15 14:36:59 kn Exp $ */
/*
* Copyright (c) 2014 Mike Larkin <mlarkin@openbsd.org>
@@ -768,8 +768,6 @@ print_vm_info(struct vmop_info_result *list, size_t ct)
(void)strlcpy(user, name, sizeof(user));
/* get group name */
if (vmi->vir_gid != -1) {
- if (vmi->vir_uid == 0)
- *user = '\0';
name = group_from_gid(vmi->vir_gid, 1);
if (name == NULL)
(void)snprintf(group, sizeof(group),