tree-wide: fix assorted typos all over the place
[safe/jmp/linux-2.6] / fs / ncpfs / ioctl.c
index fa038df..ec8f45f 100644 (file)
@@ -223,10 +223,8 @@ ncp_set_charsets(struct ncp_server* server, struct ncp_nls_ioctl __user *arg)
        oldset_io = server->nls_io;
        server->nls_io = iocharset;
 
-       if (oldset_cp)
-               unload_nls(oldset_cp);
-       if (oldset_io)
-               unload_nls(oldset_io);
+       unload_nls(oldset_cp);
+       unload_nls(oldset_io);
 
        return 0;
 }
@@ -442,7 +440,7 @@ static int __ncp_ioctl(struct inode *inode, struct file *filp,
                        if (dentry) {
                                struct inode* s_inode = dentry->d_inode;
                                
-                               if (inode) {
+                               if (s_inode) {
                                        NCP_FINFO(s_inode)->volNumber = vnum;
                                        NCP_FINFO(s_inode)->dirEntNum = de;
                                        NCP_FINFO(s_inode)->DosDirNum = dosde;
@@ -837,7 +835,7 @@ static int ncp_ioctl_need_write(unsigned int cmd)
        case NCP_IOC_SETROOT:
                return 0;
        default:
-               /* unkown IOCTL command, assume write */
+               /* unknown IOCTL command, assume write */
                return 1;
        }
 }