Date: Sun, 1 Nov 2015 17:20:17 +0000 (UTC) From: Kristof Provost <kp@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r290236 - head/sbin/pfctl Message-ID: <201511011720.tA1HKHLH060775@repo.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: kp Date: Sun Nov 1 17:20:17 2015 New Revision: 290236 URL: https://svnweb.freebsd.org/changeset/base/290236 Log: pfctl: Fix uninitialised veriable In pfctl_set_debug() we used 'level' without ever initialising it. We correctly parsed the option, but them failed to actually assign the parsed value to 'level' before performing to ioctl() to configure the debug level. PR: 202996 Submitted by: Andrej Kolontai Modified: head/sbin/pfctl/pfctl.c Modified: head/sbin/pfctl/pfctl.c ============================================================================== --- head/sbin/pfctl/pfctl.c Sun Nov 1 16:59:28 2015 (r290235) +++ head/sbin/pfctl/pfctl.c Sun Nov 1 17:20:17 2015 (r290236) @@ -1840,6 +1840,7 @@ pfctl_set_debug(struct pfctl *pf, char * } pf->debug_set = 1; + level = pf->debug; if ((pf->opts & PF_OPT_NOACTION) == 0) if (ioctl(dev, DIOCSETDEBUG, &level))
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201511011720.tA1HKHLH060775>