fs/exec.c: make bprm_mm_init() static
[firefly-linux-kernel-4.4.55.git] / fs / fcntl.c
index 8f704291d4ed812d724536f9396485abddde2089..6599222536eb20e9deb22884bdc305efcf2cf1ae 100644 (file)
@@ -30,7 +30,7 @@
 
 static int setfl(int fd, struct file * filp, unsigned long arg)
 {
-       struct inode * inode = filp->f_path.dentry->d_inode;
+       struct inode * inode = file_inode(filp);
        int error = 0;
 
        /*
@@ -258,7 +258,7 @@ static long do_fcntl(int fd, unsigned int cmd, unsigned long arg,
                err = f_dupfd(arg, filp, 0);
                break;
        case F_DUPFD_CLOEXEC:
-               err = f_dupfd(arg, filp, FD_CLOEXEC);
+               err = f_dupfd(arg, filp, O_CLOEXEC);
                break;
        case F_GETFD:
                err = get_close_on_exec(fd) ? FD_CLOEXEC : 0;