Fix MNAMELEN or reimplement struct statfs
Konstantin Belousov
kostikbel at gmail.com
Wed Nov 20 07:55:52 UTC 2013
On Tue, Nov 19, 2013 at 09:42:16AM -0800, Doug Ambrisko wrote:
> I was talking about the more general case since the system tries to keep
> the path in the stat structure. My prior approach which had more issues
> was to modify the stat structure of which I was pointed to NetBSD and their
> change to statvfs which doesn't really solve the problem. They don't
> have the check to see if the mount is longer then VFS_MNAMELEN (in their case)
> and just truncate things.
>
> If we are just talking about adding it to the mount structure that
> would be okay since it isn't exposed to user land. I can add that.
Yes, this is exactly what I mean. Add a struct mount field, and use
it for kernel only. In fact, it only matters for sys_unmount() and
kern_jail.c, other locations in kernel use the path for warnings, and
this could be postponed if you prefer to minimize the patch.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 834 bytes
Desc: not available
URL: <http://lists.freebsd.org/pipermail/freebsd-hackers/attachments/20131120/afadca7f/attachment.sig>
More information about the freebsd-hackers
mailing list