Compile fix for FUSE versions earlier than 2.8.0.

edge.strict_endians
Erik Larsson 2015-03-13 08:57:38 +01:00
parent b275f41cd8
commit 3f5d881a70
2 changed files with 12 additions and 0 deletions

View File

@ -588,7 +588,9 @@ static void ntfs_init(void *userdata __attribute__((unused)),
>= SAFE_CAPACITY_FOR_BIG_WRITES))
conn->want |= FUSE_CAP_BIG_WRITES;
#endif
#if FUSE_VERSION >= 28
conn->want |= FUSE_CAP_IOCTL_DIR;
#endif /* FUSE_VERSION >= 28 */
}
static int ntfs_fuse_getstat(struct SECURITY_CONTEXT *scx,
@ -2604,6 +2606,7 @@ static void ntfs_fuse_fsync(fuse_req_t req,
fuse_reply_err(req, 0);
}
#if FUSE_VERSION >= 28
static void ntfs_fuse_ioctl(fuse_req_t req __attribute__((unused)),
fuse_ino_t ino __attribute__((unused)),
int cmd, void *arg,
@ -2645,6 +2648,7 @@ fail :
if (buf)
free(buf);
}
#endif /* FUSE_VERSION >= 28 */
static void ntfs_fuse_bmap(fuse_req_t req, fuse_ino_t ino, size_t blocksize,
uint64_t vidx)
@ -3597,7 +3601,9 @@ static struct fuse_lowlevel_ops ntfs_3g_ops = {
.fsyncdir = ntfs_fuse_fsync,
.bmap = ntfs_fuse_bmap,
.destroy = ntfs_fuse_destroy2,
#if FUSE_VERSION >= 28
.ioctl = ntfs_fuse_ioctl,
#endif /* FUSE_VERSION >= 28 */
#if !KERNELPERMS | (POSIXACLS & !KERNELACLS)
.access = ntfs_fuse_access,
#endif

View File

@ -657,7 +657,9 @@ static void *ntfs_init(struct fuse_conn_info *conn)
>= SAFE_CAPACITY_FOR_BIG_WRITES))
conn->want |= FUSE_CAP_BIG_WRITES;
#endif
#if FUSE_VERSION >= 28
conn->want |= FUSE_CAP_IOCTL_DIR;
#endif /* FUSE_VERSION >= 28 */
return NULL;
}
@ -2444,6 +2446,7 @@ static int ntfs_fuse_fsync(const char *path __attribute__((unused)),
return (ret);
}
#if FUSE_VERSION >= 28
static int ntfs_fuse_ioctl(const char *path,
int cmd, void *arg,
struct fuse_file_info *fi __attribute__((unused)),
@ -2465,6 +2468,7 @@ static int ntfs_fuse_ioctl(const char *path,
set_fuse_error(&ret);
return ret;
}
#endif /* FUSE_VERSION >= 28 */
static int ntfs_fuse_bmap(const char *path, size_t blocksize, uint64_t *idx)
{
@ -3417,7 +3421,9 @@ static struct fuse_operations ntfs_3g_ops = {
.fsyncdir = ntfs_fuse_fsync,
.bmap = ntfs_fuse_bmap,
.destroy = ntfs_fuse_destroy2,
#if FUSE_VERSION >= 28
.ioctl = ntfs_fuse_ioctl,
#endif /* FUSE_VERSION >= 28 */
#if !KERNELPERMS | (POSIXACLS & !KERNELACLS)
.access = ntfs_fuse_access,
.opendir = ntfs_fuse_opendir,