summaryrefslogtreecommitdiff
path: root/lib/libfuse
AgeCommit message (Collapse)Author
2020-05-25from edgar pettijohn:Jason McIntyre
fix example to compile without warnings and apply style changes; ok mpi
2019-06-28When system calls indicate an error they return -1, not some arbitraryTheo de Raadt
value < 0. errno is only updated in this case. Change all (most?) callers of syscalls to follow this better, and let's see if this strictness helps us in the future.
2018-11-30Fix a typo and remove broken example.Martin Pieuchot
From Edgar Pettijohn.
2018-11-28fuse_parse_cmd_line(3) is called fuse_parse_cmdline(3).Martin Pieuchot
Based on a diff from Edgar Pettijohn III.
2018-11-16Handle signals that get sent to any threadTed Unangst
from Rian Hunter
2018-08-04tweak previous;Jason McIntyre
2018-08-04Uncomment no-longer-dead Xr.helg
2018-08-03Add man page for fuse_get_context(3).helg
2018-07-21comment out a dead Xr;Jason McIntyre
2018-07-16Implement FBT_FSYNC, which is called on fsync(2) and fdatasync(2).helg
Currently ignores the a_waitfor argument and always invokes the file system's fsync implementation synchronously. ok mpi@
2018-07-08mop up;Jason McIntyre
2018-07-08Add man page for fuse_destroy(3).helg
2018-07-08Create separate man pages for each library function.helg
2018-07-05tweak previous;Jason McIntyre
2018-07-05fuse_set_signal_handlers(3) and fuse_remove_signal_handlers(3) shouldhelg
not replace any existing signal handlers. This makes it possible for FUSE file systems to install their own signal handlers. Bug reported by Bill Zissimopoulos. ok mpi@
2018-07-05Create new man page for fuse_set_signal_handlers(3) andhelg
fuse_remove_signal_handlers(3). ok mpi@
2018-07-03Remove residual debug statements.helg
2018-06-19Changes the default mount behaviour so only the user that mounts thehelg
file system can access it unless the allow_other mount options is specified. The allow_other mount option makes the file system available to other users just like any other mounted file system. ok mpi@
2018-06-19Send the calling thread id, effective uid and gid, and umask to thehelg
FUSE file system. fuse_get_context(3) will now return the correct values. ok mpi@
2018-06-08Minor cleanup in ifuse_ops_setattr.helg
ok mpi@
2018-06-07Prevent ggc3 error: redefinition of `fuse_dirh_t'helg
OK millert@
2018-05-22Implement support for libfuse use_ino option. This returns the filehelg
system's ino for VOP_GETATTR(9) and VOP_READDIR(9) rather than the internally generated fuse ino. ok mpi@
2018-05-21Reformat debug output to one line per opcode to make it easier tohelg
interpret. ok mpi@
2018-05-20Implement FBT_FLUSH. This is sent whenever a file descriptor is closed withhelg
VOP_CLOSE(9). The associated FUSE file handle is however not closed at this time and is instead closed on VOP_RELEASE(9) because that's the only time it's guaranteed to be no longer used. Directory handles are now only closed on VOP_RELEASE(9) for the same reason. ok mpi@
2018-05-16libfuse should not maintain state for FBT_READDIR. If a directory ishelg
opened multiple times (either from the same process or different processes) then FUSE will not reliably return the directory entries to both file descriptors. ok mpi@
2018-05-15Use memset(3) instead of bzero(3) for consistency and as per POSIXhelg
recommendation.
2018-04-08Cast -1 to (unsigned long) to appease clang 6 -Wc++11-narrowingJeremie Courreges-Anglas
Fixes at least ports/archivers/fuse-zip. ok millert@
2017-12-18Add call to fuse_remove_signal_handlers(3) in fuse_teardown(3) to do thehelg
opposite of fuse_setup(3). ok mpi@
2017-12-18Refactor libfuse option processing to better support options in thehelg
future. Immediate benefits are that gid, uid and umask are now supported and max_read is now honoured for all file systems. Mounting read_only is now possible but requires more thorough testing. ok mpi@
2017-12-15Export only symbols to what's declared in fuse.h/fuse_opt.hJeremie Courreges-Anglas
While here, use guenther's magic recipe to avoid the PLT when calling exported symbols from within the library. ok kettenis@ for v1, ok guenther@ helg@
2017-12-15Fix formatting of libfuse version info.helg
ok mpi@
2017-12-14Add a missing call to fuse_set_signal_handlers(3) in fuse_setup(3) so thathelg
any file systems that call fuse_setup(3) or fuse_main(3) trap signals gracefully. ok mpi@
2017-12-14Drop -g from CFLAGS, bsd.lib.mk adds it by defaultJeremie Courreges-Anglas
ok mpi@ helg@
2017-12-14fuse_opt_add_opt_escaped needs to allocate space for the terminating NULJeremie Courreges-Anglas
Spotted by malloc.conf -> S, ok helg@
2017-12-14Free FUSE channel if fuse_new(3) fails in fuse_setup(3).helg
ok mpi@
2017-12-13Add support for the -d (-o debug) option to libfuse. Currently works for FUSEhelg
file systems that call fuse_parse_cmdline(3), fuse_main(3) or fuse_setup(3). ok mpi@, jca@
2017-12-13If the list of templates 'o' passed to fuse_opt_parse(3) is NULL thenhelg
the processing function should be called in the same way as if no match was found. ok mpi@
2017-12-11sscanf(3) is now used to parse templates that contain format specifiershelg
(e.g. %u, %o) other than %s. This aligns libfuse with the Linux reference implementation. ok mpi@
2017-12-11Update to fuse_opt_parse(3) so that all option templates are now matched forhelg
the supplied option. This allows the following templates to be supplied to set multiple members of a struct at the same time. e.g. #define FUSE_LIB_OPT(t, p, v) { t, offsetof(struct fuse_config, p), v } static const struct fuse_opt fuse_lib_opts[] = { FUSE_LIB_OPT("gid=", set_gid, 1), FUSE_LIB_OPT("gid=%u", gid, 0), FUSE_OPT_END }; If "-ogid=1000" is passed to fuse_opt_parse(3) it will set both: fuse_config.set_gid=1 fuse_config.gid=1000 ok mpi@
2017-12-11The fuse_opt_match(3) library function does not match options correctly.helg
libfuse supports option templates of the following form that can be used to automatically parse arguments supplied on the command line. "-p " argument that takes an option e.g -p 22 or -p22 "-p %x" argument that takes an option parsed like sscanf(3) "cache=yes" matches -ocache=yes or -o cache=yes "cache=%s" matches -ocache=<string> or -o cache=<string> "cache=" matches same as above but value is passed to option proc "noatime" matches -onoatime or -o atime For example, it does not match options of the form "-p 22" or "cache=yes" to the corresponding templates "-p " and "cache=yes". This patch fixes that and updates the regression tests accordingly. ok mpi@
2017-11-30vn_open(9) does not pass the open(2) flags to VOP_CREATE(9) so we can'thelg
support FBT_CREATE. Fall back to FBT_MKNOD + FBT_OPEN so that a valid sequence of FUSE messages is sent to the file system when creating files. input from mpi@, otto@
2017-11-26Add support for -f option to libfuse. This keeps the FUSE file systemhelg
running in the foreground. ok mpi@
2017-11-17Implement safe signal handling and handle unmount failure gracefully.helg
ok mpi@
2017-11-17Fixes the following bugs when getcwd(3) is used on a fuse file systemhelg
Endless loop if directory nested more than one level from root of file system Current directory not found if the parent directory contains more children than will fit in the buffer passed to VOP_READDIR(9) Open and close directory in fusefs_readdir if dir is not already open. Now behaves as if readdir_ino option was passed to fuse so that directories in path have a valid ino. ok mpi@
2017-11-16Add support for:helg
multiple options after -o. arguments that require options e.g. -p 22 %s, %lu, %u option templates ok mpi@
2017-11-04fuse_loop_mt() isn't implemented so return an error value.Martin Pieuchot
From Helg Bredow.
2017-11-04Use the correct version macro.Martin Pieuchot
From Helg Bredow, ok pirofti@
2017-11-02Check if the arguments are NULL instead of dereferencing them blindly.Martin Pieuchot
Delete incorrect "unused" keyword and remove redundant variables due to missing NULL checks. From Helg Bredow.
2017-10-25Check for NULL before dereferencing untrusted pointers.Martin Pieuchot
from Helg Bredow.
2017-10-24Add more sanity checks to prevent a segfault and a NULL-dereferenceMartin Pieuchot
when manipulating callers probided pointers. From Helg Bredow.