diff options
author | YASUOKA Masahiko <yasuoka@cvs.openbsd.org> | 2015-05-12 05:30:25 +0000 |
---|---|---|
committer | YASUOKA Masahiko <yasuoka@cvs.openbsd.org> | 2015-05-12 05:30:25 +0000 |
commit | 9ee04eecbacf8db3c9fff94fece827c870e24bff (patch) | |
tree | 191c2b63e8636aca92024ec6736efc81f972154a | |
parent | bb2f38b96616ed6987a3e49eb009c4be112e4c6f (diff) |
Fix an uninitialized variable access when pptp.hostname is configured.
-rw-r--r-- | usr.sbin/npppd/pptp/pptp_ctrl.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/usr.sbin/npppd/pptp/pptp_ctrl.c b/usr.sbin/npppd/pptp/pptp_ctrl.c index 80de9c12ea2..1dfdc030b87 100644 --- a/usr.sbin/npppd/pptp/pptp_ctrl.c +++ b/usr.sbin/npppd/pptp/pptp_ctrl.c @@ -1,4 +1,4 @@ -/* $OpenBSD: pptp_ctrl.c,v 1.9 2015/01/19 01:48:59 deraadt Exp $ */ +/* $OpenBSD: pptp_ctrl.c,v 1.10 2015/05/12 05:30:24 yasuoka Exp $ */ /*- * Copyright (c) 2009 Internet Initiative Japan Inc. @@ -29,7 +29,7 @@ * PPTP(RFC 2637) control connection implementation. * currently it only support PAC part */ -/* $Id: pptp_ctrl.c,v 1.9 2015/01/19 01:48:59 deraadt Exp $ */ +/* $Id: pptp_ctrl.c,v 1.10 2015/05/12 05:30:24 yasuoka Exp $ */ #include <sys/types.h> #include <sys/socket.h> #include <netinet/in.h> @@ -749,7 +749,7 @@ pptp_ctrl_send_SCCRP(pptp_ctrl *_this, int result, int error) * 63 character */ /* host name */ - if (PPTP_CTRL_CONF(_this)->hostname == NULL) + if ((val = PPTP_CTRL_CONF(_this)->hostname) == NULL) val = ""; strlcpy(scc->host_name, val, sizeof(scc->host_name)); |