aboutsummaryrefslogtreecommitdiffstats
path: root/fs/cifs/dir.c
diff options
context:
space:
mode:
Diffstat (limited to 'fs/cifs/dir.c')
-rw-r--r--fs/cifs/dir.c5
1 files changed, 1 insertions, 4 deletions
diff --git a/fs/cifs/dir.c b/fs/cifs/dir.c
index d364654491e3..2caba0b54acb 100644
--- a/fs/cifs/dir.c
+++ b/fs/cifs/dir.c
@@ -387,7 +387,6 @@ cifs_atomic_open(struct inode *inode, struct dentry *direntry,
387 struct cifs_tcon *tcon; 387 struct cifs_tcon *tcon;
388 __u16 fileHandle; 388 __u16 fileHandle;
389 __u32 oplock; 389 __u32 oplock;
390 struct file *filp;
391 struct cifsFileInfo *pfile_info; 390 struct cifsFileInfo *pfile_info;
392 391
393 /* Posix open is only called (at lookup time) for file create now. For 392 /* Posix open is only called (at lookup time) for file create now. For
@@ -418,7 +417,6 @@ cifs_atomic_open(struct inode *inode, struct dentry *direntry,
418 inode, direntry->d_name.name, direntry); 417 inode, direntry->d_name.name, direntry);
419 418
420 tlink = cifs_sb_tlink(CIFS_SB(inode->i_sb)); 419 tlink = cifs_sb_tlink(CIFS_SB(inode->i_sb));
421 filp = ERR_CAST(tlink);
422 if (IS_ERR(tlink)) 420 if (IS_ERR(tlink))
423 goto out_free_xid; 421 goto out_free_xid;
424 422
@@ -436,10 +434,9 @@ cifs_atomic_open(struct inode *inode, struct dentry *direntry,
436 goto out; 434 goto out;
437 } 435 }
438 436
439 pfile_info = cifs_new_fileinfo(fileHandle, filp, tlink, oplock); 437 pfile_info = cifs_new_fileinfo(fileHandle, file, tlink, oplock);
440 if (pfile_info == NULL) { 438 if (pfile_info == NULL) {
441 CIFSSMBClose(xid, tcon, fileHandle); 439 CIFSSMBClose(xid, tcon, fileHandle);
442 fput(filp);
443 rc = -ENOMEM; 440 rc = -ENOMEM;
444 } 441 }
445 442