Fix panic in CTL caused by trying to free invalid pointers passed

by the userland process via the IOCTL interface.

Reviewed by:	ken@
This commit is contained in:
Edward Tomasz Napierala 2012-09-26 07:09:15 +00:00
parent 7403d1b9b2
commit 43f3d8e372

View file

@ -2074,6 +2074,11 @@ ctl_copyin_args(int num_be_args, struct ctl_be_arg *be_args,
if (args == NULL)
goto bailout;
for (i = 0; i < num_be_args; i++) {
args[i].kname = NULL;
args[i].kvalue = NULL;
}
for (i = 0; i < num_be_args; i++) {
uint8_t *tmpptr;