new helper: file_inode(file)
[linux-block.git] / security / apparmor / domain.c
index 60f0c76a27d3cec1afe576104ef831fe577c54e1..859abdaac1eafb62fddb202eb6fcdf3777e9daa2 100644 (file)
@@ -349,8 +349,8 @@ int apparmor_bprm_set_creds(struct linux_binprm *bprm)
        unsigned int state;
        struct file_perms perms = {};
        struct path_cond cond = {
-               bprm->file->f_path.dentry->d_inode->i_uid,
-               bprm->file->f_path.dentry->d_inode->i_mode
+               file_inode(bprm->file)->i_uid,
+               file_inode(bprm->file)->i_mode
        };
        const char *name = NULL, *target = NULL, *info = NULL;
        int error = cap_bprm_set_creds(bprm);