Date: Thu, 31 Oct 2002 13:33:45 -0800 (PST) From: Robert Watson <rwatson@FreeBSD.org> To: Perforce Change Reviews <perforce@freebsd.org> Subject: PERFORCE change 20493 for review Message-ID: <200210312133.g9VLXjos019025@repoman.freebsd.org>
next in thread | raw e-mail | index | archive | help
http://perforce.freebsd.org/chv.cgi?CH=20493 Change 20493 by rwatson@rwatson_tislabs on 2002/10/31 13:33:40 Trim redundant suser() check for hostname setting: the sysctl code already does this check so we don't need it here. Affected files ... .. //depot/projects/trustedbsd/mac/sys/kern/kern_xxx.c#4 edit Differences ... ==== //depot/projects/trustedbsd/mac/sys/kern/kern_xxx.c#4 (text+ko) ==== @@ -97,10 +97,8 @@ name[0] = CTL_KERN; name[1] = KERN_HOSTNAME; mtx_lock(&Giant); - if ((error = suser_cred(td->td_ucred, PRISON_ROOT)) == 0) { - error = userland_sysctl(td, name, 2, 0, 0, 0, - uap->hostname, uap->len, 0); - } + error = userland_sysctl(td, name, 2, 0, 0, 0, uap->hostname, + uap->len, 0); mtx_unlock(&Giant); return (error); } To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe p4-projects" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200210312133.g9VLXjos019025>