Giuseppe Scrivano
7e54c97400
main: fix read after free
...
Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2019-07-25 15:46:53 +02:00
Giuseppe Scrivano
79c802f61e
main, open: avoid a lookup if the node is known
...
Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2019-07-25 10:12:11 +02:00
Giuseppe Scrivano
80a0260043
file, open: do not double close fd
...
Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2019-07-25 10:12:10 +02:00
Giuseppe Scrivano
dd744c7fc2
file, open: avoid deleting the whiteout if possible
...
Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2019-07-25 10:12:09 +02:00
Giuseppe Scrivano
6dbc45b821
file, open: create directly the file if possible
...
Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2019-07-25 10:12:08 +02:00
Giuseppe Scrivano
348f60a277
file, open: move code to create a file to its function
...
Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2019-07-24 17:05:51 +02:00
Giuseppe Scrivano
2404d5f9b1
main, mkdir: create directly the directory if possible
...
Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2019-07-24 16:38:01 +02:00
Giuseppe Scrivano
3286532636
main, symlink: avoid a chown if it is not needed
...
Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2019-07-24 16:10:14 +02:00
Giuseppe Scrivano
a77edee351
main, open: avoid a chown if it is not needed
...
Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2019-07-24 16:09:08 +02:00
Giuseppe Scrivano
0749dd7fb8
main, copyup: avoid a chown if it is not needed
...
Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2019-07-24 16:04:38 +02:00
Giuseppe Scrivano
74fa25112a
main, mkdir: avoid a chown if it is not needed
...
Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2019-07-24 16:03:58 +02:00
Giuseppe Scrivano
1395753e1a
main, fsync: if fsync is disabled return ENOSYS
...
Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2019-07-23 16:14:40 +02:00
Giuseppe Scrivano
99206771b5
main, symlink: skip delete whiteout if not needed
...
Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2019-07-23 16:14:39 +02:00
Giuseppe Scrivano
c174cef9f3
main, mkdir: delete whiteout only if necessary
...
Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2019-07-23 16:14:38 +02:00
Giuseppe Scrivano
1651770837
main: accept atime/noatime
...
Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2019-07-23 16:14:37 +02:00
Giuseppe Scrivano
fcfd937a3d
main, unlink: do not create a whiteout if not necessary
...
if the parent dir is on the upper layer only, there is no need to
create a whiteout file.
Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2019-07-23 16:14:37 +02:00
Giuseppe Scrivano
87deb1d458
main: assume workdir is empty on startup
...
Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2019-07-23 16:14:36 +02:00
Giuseppe Scrivano
c99226b70b
main: skip RENAME_WHITEOUT if we cannot use mknod
...
Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2019-07-23 16:14:35 +02:00
Giuseppe Scrivano
a4ebbc8361
main: give hint on debugging being disabled
...
Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2019-07-23 16:14:34 +02:00
Giuseppe Scrivano
c2d45f7843
main, access: use the cached mode
...
Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2019-07-23 16:14:34 +02:00
Giuseppe Scrivano
1237d05c1a
main, readdir: use only st_mode and st_ino
...
Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2019-07-23 16:14:33 +02:00
Giuseppe Scrivano
551638090f
main: cache inode st_mode
...
Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2019-07-23 16:14:32 +02:00
Giuseppe Scrivano
1545d4bf84
main, mkdir: reuse stat when possible
...
Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2019-07-23 16:14:31 +02:00
Giuseppe Scrivano
c5bfc0ba87
main: use malloc instead of calloc
...
the memory will be overwritten.
Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2019-07-23 16:14:31 +02:00
Giuseppe Scrivano
605e17fbf7
main: rpl_stat can reuse existing struct stat
...
Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2019-07-23 16:14:30 +02:00
Giuseppe Scrivano
98aeb52ac2
main, mkdir: do not lookup lower layers if not needed
...
if the parent directory is only on the upper layer, there is no need
to look for the ino in the lower layers.
Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2019-07-23 16:14:29 +02:00
Giuseppe Scrivano
f3d66013b3
main: drop present_lowerdir attribute
...
use last_layer instead.
Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2019-07-23 16:14:28 +02:00
Giuseppe Scrivano
64e493e7e4
main: create_directory does unlink only on ENOTDIR
...
Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2019-07-23 16:14:28 +02:00
Giuseppe Scrivano
cbf7881f01
main: load_dir updates the node last layer
...
Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2019-07-23 16:14:27 +02:00
Giuseppe Scrivano
4f3862db82
build: fix build with older versions of libfuse
...
Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2019-07-23 16:02:14 +02:00
Giuseppe Scrivano
9e20d96bbf
main: store negative lookups
...
Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2019-07-22 23:17:04 +02:00
Giuseppe Scrivano
1bed1d566b
main: cache if the node has security.capability
...
Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2019-07-22 23:17:04 +02:00
Giuseppe Scrivano
3b0ff43029
main: accept kernel_cache option
...
Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2019-07-22 15:37:30 +02:00
Giuseppe Scrivano
53d93f5938
main: specify FUSE_CAP_SPLICE_MOVE
...
Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2019-07-22 15:37:29 +02:00
Giuseppe Scrivano
c1fa9afe1e
main: set keep_cache on open
...
Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2019-07-22 15:37:29 +02:00
Giuseppe Scrivano
a87044ebfc
main: change initial hash map size to 128
...
Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2019-07-22 13:07:28 +02:00
Giuseppe Scrivano
3154fc0e91
main: cache directory nlinks
...
Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2019-07-22 12:38:34 +02:00
Giuseppe Scrivano
1cabb17dd3
main: provide implementation for forget_multi
...
Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2019-07-22 12:34:41 +02:00
Giuseppe Scrivano
648f158cac
main: provide implementation for copy_file_range
...
Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2019-07-22 12:34:41 +02:00
Giuseppe Scrivano
b0bc506690
main: provide implementation for fallocate
...
Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2019-07-22 12:34:40 +02:00
Giuseppe Scrivano
784b3fd549
main: don't take the lock if sync is disabled
...
Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2019-07-22 12:34:39 +02:00
Giuseppe Scrivano
9a4840b8d5
main: provide fsyncdir
...
Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2019-07-22 12:34:38 +02:00
Giuseppe Scrivano
beeafcfc62
main: report close(2) errors
...
Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2019-07-22 12:34:38 +02:00
Giuseppe Scrivano
9e2e1cbbd1
main: add debugging message for ovl_release
...
Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2019-07-22 12:34:37 +02:00
Giuseppe Scrivano
58e9351619
main: reload directory only when necessary
...
Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2019-07-22 12:34:35 +02:00
Giuseppe Scrivano
216ef5ef48
main: skip lookup if the directory is fully loaded
...
avoid doing a lookup in the lower layers if the directory is already
loaded.
Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2019-07-22 12:34:34 +02:00
Giuseppe Scrivano
cefd924c7a
main: xattr, not resolve symlinks
...
Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2019-07-22 12:34:32 +02:00
Giuseppe Scrivano
d1c21f2572
main: add option to disable xattrs
...
Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2019-07-22 12:34:32 +02:00
Giuseppe Scrivano
35949df0bb
fuse: support writeback cache and enable it by default
...
Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2019-07-22 12:34:31 +02:00
Giuseppe Scrivano
1b30118ef3
main: ignore ctime requests instead of EPERM
...
Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2019-07-22 12:34:30 +02:00