Date: Sun, 6 Jun 2004 19:38:14 +0000 (UTC) From: "Bjoern A. Zeeb" <bzeeb-lists@lists.zabbadoz.net> To: FreeBSD current mailing list <current@freebsd.org> Subject: vfs_syscalls / fhstatfs / suser() Message-ID: <Pine.BSF.4.53.0406061932520.62813@e0-0.zab2.int.zabbadoz.net>
next in thread | raw e-mail | index | archive | help
Hi, if I am not wrong the part removed by the atatched diff is not needed because at the very beginning of the function there is a error = suser(td); if (error) return (error); so a second check should never become true again (if threads cannot be move in and out of jails). please correct me if I am wrong. --- ./vfs_syscalls.c.orig Sun Jun 6 19:32:23 2004 +++ ./vfs_syscalls.c Sun Jun 6 19:33:12 2004 @@ -4128,11 +4128,6 @@ fhstatfs(td, uap) sp->f_flags = mp->mnt_flag & MNT_VISFLAGMASK; if ((error = VFS_STATFS(mp, sp, td)) != 0) return (error); - if (suser(td)) { - bcopy(sp, &sb, sizeof(sb)); - sb.f_fsid.val[0] = sb.f_fsid.val[1] = 0; - sp = &sb; - } return (copyout(sp, uap->buf, sizeof(*sp))); } -- Bjoern A. Zeeb bzeeb at Zabbadoz dot NeT
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?Pine.BSF.4.53.0406061932520.62813>