From: mlarkin Date: Wed, 12 May 2021 02:24:56 +0000 (+0000) Subject: vmd(8): omit a possibly uninitialized var in a log_warnx X-Git-Url: http://artulab.com/gitweb/?a=commitdiff_plain;h=f6eb31162e647f7dcd5edda1e0961e09f5fe39e3;p=openbsd vmd(8): omit a possibly uninitialized var in a log_warnx Don't print 'base' since it might not be initialized in all code paths. From James Cook --- diff --git a/usr.sbin/vmd/config.c b/usr.sbin/vmd/config.c index 46acf78ce8a..83c6c1e9b4d 100644 --- a/usr.sbin/vmd/config.c +++ b/usr.sbin/vmd/config.c @@ -1,4 +1,4 @@ -/* $OpenBSD: config.c,v 1.61 2021/03/29 23:37:01 dv Exp $ */ +/* $OpenBSD: config.c,v 1.62 2021/05/12 02:24:56 mlarkin Exp $ */ /* * Copyright (c) 2015 Reyk Floeter @@ -386,8 +386,8 @@ config_setvm(struct privsep *ps, struct vmd_vm *vm, uint32_t peerid, uid_t uid) break; if (n == -1) { log_warnx("vm \"%s\" unable to read " - "base %s for disk %s", vcp->vcp_name, - base, vcp->vcp_disks[i]); + "base for disk %s", vcp->vcp_name, + vcp->vcp_disks[i]); goto fail; } (void)strlcpy(path, base, sizeof(path));