]> Pileus Git - ~andy/linux/blobdiff - fs/cifs/ioctl.c
Merge branch 'sched-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel...
[~andy/linux] / fs / cifs / ioctl.c
index 5c792df13d62f518224378a0c9a795d9440040a7..f94650683a00355d48f6fa545e72baaf6721e95e 100644 (file)
@@ -30,9 +30,9 @@
 
 #define CIFS_IOC_CHECKUMOUNT _IO(0xCF, 2)
 
-int cifs_ioctl(struct inode *inode, struct file *filep,
-               unsigned int command, unsigned long arg)
+long cifs_ioctl(struct file *filep, unsigned int command, unsigned long arg)
 {
+       struct inode *inode = filep->f_dentry->d_inode;
        int rc = -ENOTTY; /* strange error - but the precedent */
        int xid;
        struct cifs_sb_info *cifs_sb;
@@ -65,7 +65,7 @@ int cifs_ioctl(struct inode *inode, struct file *filep,
        switch (command) {
                case CIFS_IOC_CHECKUMOUNT:
                        cFYI(1, ("User unmount attempted"));
-                       if (cifs_sb->mnt_uid == current->uid)
+                       if (cifs_sb->mnt_uid == current_uid())
                                rc = 0;
                        else {
                                rc = -EACCES;