summaryrefslogtreecommitdiffstats
path: root/sys/kern/kern_tame.c
diff options
context:
space:
mode:
authordoug <doug@openbsd.org>2015-08-24 06:17:48 +0000
committerdoug <doug@openbsd.org>2015-08-24 06:17:48 +0000
commit1e431253630dd59b6303f15a3af21f9f1afbad6f (patch)
tree2ca1e1033935346cc9a7c9f714f62ca531b32d20 /sys/kern/kern_tame.c
parentAudio on the T400/T410/T510/T420/T520/X220/X220t docks needs a quirk (diff)
downloadwireguard-openbsd-1e431253630dd59b6303f15a3af21f9f1afbad6f.tar.xz
wireguard-openbsd-1e431253630dd59b6303f15a3af21f9f1afbad6f.zip
Initialize cwdpath so free() is properly handled.
ok deraadt@
Diffstat (limited to 'sys/kern/kern_tame.c')
-rw-r--r--sys/kern/kern_tame.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/sys/kern/kern_tame.c b/sys/kern/kern_tame.c
index cfe77fc4fff..c453ac3efdb 100644
--- a/sys/kern/kern_tame.c
+++ b/sys/kern/kern_tame.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: kern_tame.c,v 1.26 2015/08/23 21:30:04 deraadt Exp $ */
+/* $OpenBSD: kern_tame.c,v 1.27 2015/08/24 06:17:48 doug Exp $ */
/*
* Copyright (c) 2015 Nicholas Marriott <nicm@openbsd.org>
@@ -519,7 +519,7 @@ tame_namei(struct proc *p, char *origpath)
if (p->p_p->ps_tamepaths) {
struct whitepaths *wl = p->p_p->ps_tamepaths;
char *fullpath = path, *builtpath = NULL, *canopath = NULL;
- char *cwdpath, *cwd;
+ char *cwdpath = NULL, *cwd;
size_t cwdpathlen, cwdlen, builtlen;
int i, error;