From 22ca8a5a79173b78f0bef1e3afa34e7518b69576 Mon Sep 17 00:00:00 2001 From: Jeff Layton Date: Mon, 24 Oct 2016 10:02:59 -0400 Subject: [PATCH] client: convert ceph_ll_open to take a UserPerm pointer Signed-off-by: Jeff Layton --- src/include/cephfs/libcephfs.h | 2 +- src/libcephfs.cc | 5 ++--- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/src/include/cephfs/libcephfs.h b/src/include/cephfs/libcephfs.h index 3c6334c35e4..1401371ce4c 100644 --- a/src/include/cephfs/libcephfs.h +++ b/src/include/cephfs/libcephfs.h @@ -1440,7 +1440,7 @@ int ceph_ll_getattr(struct ceph_mount_info *cmount, struct Inode *in, int ceph_ll_setattr(struct ceph_mount_info *cmount, struct Inode *in, struct ceph_statx *stx, int mask, const UserPerm *perms); int ceph_ll_open(struct ceph_mount_info *cmount, struct Inode *in, int flags, - struct Fh **fh, int uid, int gid); + struct Fh **fh, const UserPerm *perms); off_t ceph_ll_lseek(struct ceph_mount_info *cmount, struct Fh* filehandle, off_t offset, int whence); int ceph_ll_read(struct ceph_mount_info *cmount, struct Fh* filehandle, diff --git a/src/libcephfs.cc b/src/libcephfs.cc index 0a3fbb29091..5b880aa2ef3 100644 --- a/src/libcephfs.cc +++ b/src/libcephfs.cc @@ -1445,10 +1445,9 @@ extern "C" int ceph_ll_setattr(class ceph_mount_info *cmount, } extern "C" int ceph_ll_open(class ceph_mount_info *cmount, Inode *in, - int flags, Fh **fh, int uid, int gid) + int flags, Fh **fh, const UserPerm *perms) { - UserPerm perms(uid, gid); - return (cmount->get_client()->ll_open(in, flags, fh, perms)); + return (cmount->get_client()->ll_open(in, flags, fh, *perms)); } extern "C" int ceph_ll_read(class ceph_mount_info *cmount, Fh* filehandle, -- 2.47.3