mirror of
https://github.com/containers/fuse-overlayfs.git
synced 2025-09-09 07:16:11 -04:00
main: fix type for ioctl
fuse_reply_ioctl expects a int. Closes: https://github.com/containers/fuse-overlayfs/issues/330 Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
This commit is contained in:
parent
6d4dbb88fc
commit
0476f8464b
10
main.c
10
main.c
@ -5131,12 +5131,6 @@ ovl_fsyncdir (fuse_req_t req, fuse_ino_t ino, int datasync, struct fuse_file_inf
|
||||
return do_fsync (req, ino, datasync, -1);
|
||||
}
|
||||
|
||||
static int
|
||||
direct_ioctl (struct ovl_layer *l, int fd, int cmd, unsigned long *r)
|
||||
{
|
||||
return ioctl (fd, cmd, &r);
|
||||
}
|
||||
|
||||
static void
|
||||
ovl_ioctl (fuse_req_t req, fuse_ino_t ino, int cmd, void *arg,
|
||||
struct fuse_file_info *fi, unsigned int flags,
|
||||
@ -5147,7 +5141,7 @@ ovl_ioctl (fuse_req_t req, fuse_ino_t ino, int cmd, void *arg,
|
||||
cleanup_close int cleaned_fd = -1;
|
||||
struct ovl_node *node;
|
||||
int fd = -1;
|
||||
unsigned long r;
|
||||
int r = 0;
|
||||
|
||||
if (flags & FUSE_IOCTL_COMPAT)
|
||||
{
|
||||
@ -5203,7 +5197,7 @@ ovl_ioctl (fuse_req_t req, fuse_ino_t ino, int cmd, void *arg,
|
||||
|
||||
l = release_big_lock ();
|
||||
|
||||
if (direct_ioctl (node->layer, fd, cmd, &r) < 0)
|
||||
if (ioctl (fd, cmd, &r, sizeof (r)) < 0)
|
||||
fuse_reply_err (req, errno);
|
||||
else
|
||||
fuse_reply_ioctl (req, 0, &r, out_bufsz ? sizeof (r) : 0);
|
||||
|
Loading…
x
Reference in New Issue
Block a user