From e4015aca9b7ba0c787ad8d07f7d9db18d3bbc211 Mon Sep 17 00:00:00 2001 From: Nikolaus Rath Date: Mon, 3 Oct 2016 20:27:02 -0700 Subject: Merge master fuse_chan into fuse_session. This is a code simplification patch. - It confines most of the implementation channel implementation into fuse_loop_mt (which is its only user). - It makes it more obvious in the code that channels are only ever used when using -o clone_fd and multi-threaded main loop. - It simplies the definition of both struct fuse_session and struct fuse_chan. - Theoretically it should result in (minuscule) performance improvements when not using -o clone_fd. - Overall, it removes a lot more lines of source code than it adds :-). --- lib/fuse_loop.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'lib/fuse_loop.c') diff --git a/lib/fuse_loop.c b/lib/fuse_loop.c index 8414284..4a85b13 100644 --- a/lib/fuse_loop.c +++ b/lib/fuse_loop.c @@ -19,20 +19,19 @@ int fuse_session_loop(struct fuse_session *se) { int res = 0; - struct fuse_chan *ch = fuse_session_chan(se); struct fuse_buf fbuf = { .mem = NULL, }; while (!fuse_session_exited(se)) { - res = fuse_session_receive_buf_int(se, &fbuf, ch); + res = fuse_session_receive_buf_int(se, &fbuf, NULL); if (res == -EINTR) continue; if (res <= 0) break; - fuse_session_process_buf_int(se, &fbuf, ch); + fuse_session_process_buf_int(se, &fbuf, NULL); } free(fbuf.mem); -- cgit v1.2.3