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
This commit is contained in:
kp 2015-11-01 17:20:17 +00:00
parent 02dfa34a88
commit 412c34d241

View File

@ -1840,6 +1840,7 @@ pfctl_set_debug(struct pfctl *pf, char *d)
}
pf->debug_set = 1;
level = pf->debug;
if ((pf->opts & PF_OPT_NOACTION) == 0)
if (ioctl(dev, DIOCSETDEBUG, &level))