diff options
author | Joanne Koong <joannelkoong@gmail.com> | 2024-09-26 17:33:39 -0700 |
---|---|---|
committer | Bernd Schubert <bernd.schubert@fastmail.fm> | 2024-09-28 12:24:25 +0200 |
commit | 9069ad9eb6ba908de9cbbdd8ba411cac963101ff (patch) | |
tree | bf71e09ee17e50ce571644dc3aaf33209a120e23 /lib/fuse_lowlevel.c | |
parent | 78eeae60bb5a978eae4c3ce705c58189b762a24b (diff) | |
download | libfuse-9069ad9eb6ba908de9cbbdd8ba411cac963101ff.tar.gz |
Change FUSE_MAX_MAX_PAGES to FUSE_DEFAULT_MAX_PAGES_LIMIT
A recent upstream patch [1] changed FUSE_MAX_MAX_PAGES to
FUSE_DEFAULT_MAX_PAGES_LIMIT.
Update libfuse to use FUSE_DEFAULT_MAX_PAGES_LIMIT as well
instead of FUSE_MAX_MAX_PAGES.
[1] https://lore.kernel.org/linux-fsdevel/20240923171311.1561917-1-joannelkoong@gmail.com/T/#t
Diffstat (limited to 'lib/fuse_lowlevel.c')
-rw-r--r-- | lib/fuse_lowlevel.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/fuse_lowlevel.c b/lib/fuse_lowlevel.c index 824dbab..819e435 100644 --- a/lib/fuse_lowlevel.c +++ b/lib/fuse_lowlevel.c @@ -2915,19 +2915,19 @@ static unsigned int get_max_pages(void) fd = open("/proc/sys/fs/fuse/max_pages_limit", O_RDONLY); if (fd < 0) - return FUSE_MAX_MAX_PAGES; + return FUSE_DEFAULT_MAX_PAGES_LIMIT; res = read(fd, buf, sizeof(buf) - 1); close(fd); if (res < 0) - return FUSE_MAX_MAX_PAGES; + return FUSE_DEFAULT_MAX_PAGES_LIMIT; buf[res] = '\0'; res = strtol(buf, NULL, 10); - return res < 0 ? FUSE_MAX_MAX_PAGES : res; + return res < 0 ? FUSE_DEFAULT_MAX_PAGES_LIMIT : res; } int fuse_session_receive_buf(struct fuse_session *se, struct fuse_buf *buf) |