Date: Fri, 25 Mar 2011 11:05:29 +0000 (UTC) From: Konstantin Belousov <kib@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r219987 - head/sys/compat/freebsd32 Message-ID: <201103251105.p2PB5T1r079116@svn.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: kib Date: Fri Mar 25 11:05:28 2011 New Revision: 219987 URL: http://svn.freebsd.org/changeset/base/219987 Log: Remove unneccessary panics, that can be easily triggered by user. The copyin() function handles NULL as well as any other pointer. MFC after: 3 days Modified: head/sys/compat/freebsd32/freebsd32_ioctl.c Modified: head/sys/compat/freebsd32/freebsd32_ioctl.c ============================================================================== --- head/sys/compat/freebsd32/freebsd32_ioctl.c Fri Mar 25 10:57:57 2011 (r219986) +++ head/sys/compat/freebsd32/freebsd32_ioctl.c Fri Mar 25 11:05:28 2011 (r219987) @@ -66,8 +66,6 @@ freebsd32_ioctl_md(struct thread *td, st u_long com = 0; int error; - if (uap->data == NULL) - panic("%s: where is my ioctl data??", __func__); if (uap->com & IOC_IN) { if ((error = copyin(uap->data, &md32, sizeof(md32)))) { return (error); @@ -132,9 +130,6 @@ freebsd32_ioctl_ioc_toc_header(struct th struct ioc_toc_header32 toch32; int error; - if (uap->data == NULL) - panic("%s: where is my ioctl data??", __func__); - if ((error = copyin(uap->data, &toch32, sizeof(toch32)))) return (error); CP(toch32, toch, len); @@ -154,9 +149,6 @@ freebsd32_ioctl_ioc_read_toc(struct thre struct ioc_read_toc_entry32 toce32; int error; - if (uap->data == NULL) - panic("%s: where is my ioctl data??", __func__); - if ((error = copyin(uap->data, &toce32, sizeof(toce32)))) return (error); CP(toce32, toce, address_format);
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201103251105.p2PB5T1r079116>