aboutsummaryrefslogtreecommitdiff
path: root/lib/fuse_lowlevel.c
diff options
context:
space:
mode:
authorGravatar Nikolaus Rath <Nikolaus@rath.org>2016-10-03 20:09:35 -0700
committerGravatar Nikolaus Rath <Nikolaus@rath.org>2016-10-03 23:01:46 -0700
commit292fb198f108f46458008066827da965be8a4334 (patch)
tree5d8251ddd05210e2423f753602d6ddc4c866df62 /lib/fuse_lowlevel.c
parentea471967c94035287cebc13ba6e24f6cda6daafd (diff)
Store struct fuse_session* in struct fuse_req
Diffstat (limited to 'lib/fuse_lowlevel.c')
-rw-r--r--lib/fuse_lowlevel.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/lib/fuse_lowlevel.c b/lib/fuse_lowlevel.c
index 375ac69..82cbe06 100644
--- a/lib/fuse_lowlevel.c
+++ b/lib/fuse_lowlevel.c
@@ -144,7 +144,7 @@ void fuse_free_req(fuse_req_t req)
destroy_req(req);
}
-static struct fuse_req *fuse_ll_alloc_req(struct fuse_ll *f)
+static struct fuse_req *fuse_ll_alloc_req(struct fuse_session *se)
{
struct fuse_req *req;
@@ -152,7 +152,8 @@ static struct fuse_req *fuse_ll_alloc_req(struct fuse_ll *f)
if (req == NULL) {
fprintf(stderr, "fuse: failed to allocate request\n");
} else {
- req->f = f;
+ req->f = se->f;
+ req->se = se;
req->ctr = 1;
list_init_req(req);
fuse_mutex_init(&req->lock);
@@ -1075,7 +1076,7 @@ static void do_batch_forget(fuse_req_t req, fuse_ino_t nodeid,
struct fuse_forget_one *forget = &param[i];
struct fuse_req *dummy_req;
- dummy_req = fuse_ll_alloc_req(req->f);
+ dummy_req = fuse_ll_alloc_req(req->se);
if (dummy_req == NULL)
break;
@@ -2488,7 +2489,7 @@ void fuse_session_process_buf_int(struct fuse_session *se,
(unsigned long long) in->nodeid, buf->size, in->pid);
}
- req = fuse_ll_alloc_req(f);
+ req = fuse_ll_alloc_req(se);
if (req == NULL) {
struct fuse_out_header out = {
.unique = in->unique,