Subject: Re: bin/3615: umount change to allow relative path unmounting
To: None <nimenees@par0163.urh.uiuc.edu>
From: Chris G. Demetriou <cgd@pa.dec.com>
List: netbsd-bugs
Date: 05/13/1997 16:42:56
> *** vfs_syscalls.c.old  Tue May 13 18:08:48 1997
> --- vfs_syscalls.c      Tue May 13 18:30:31 1997
> *************** sys_mount(p, v, retval)
> *** 93,98 ****
> --- 93,100 ----
>         struct vattr va;
>         struct nameidata nd;
>   
> +       if (*(SCARG(uap, path)) != '/')
> +               return (ENOENT);
>         /*
>          * Get vnode to be covered
>          */

Not on all architectures, by any means.  you can't safely access the
contents of 'path' without copying them into kernel space.

also, the return value for such a check should be EINVAL, not ENOENT.


cgd