]> err.no Git - linux-2.6/blobdiff - fs/smbfs/dir.c
NFS: remove user_addr, user_count, and pos from nfs_direct_req
[linux-2.6] / fs / smbfs / dir.c
index 34c7a11d91f0ebbb29854a0116d8c558825fbbbc..70d9c5a37f5a3c6f7d5cad12e7bad8e1d2e21136 100644 (file)
@@ -434,6 +434,11 @@ smb_lookup(struct inode *dir, struct dentry *dentry, struct nameidata *nd)
        if (dentry->d_name.len > SMB_MAXNAMELEN)
                goto out;
 
+       /* Do not allow lookup of names with backslashes in */
+       error = -EINVAL;
+       if (memchr(dentry->d_name.name, '\\', dentry->d_name.len))
+               goto out;
+
        lock_kernel();
        error = smb_proc_getattr(dentry, &finfo);
 #ifdef SMBFS_PARANOIA