diff options
author | Miklos Szeredi <miklos@szeredi.hu> | 2001-11-06 12:03:23 +0000 |
---|---|---|
committer | Miklos Szeredi <miklos@szeredi.hu> | 2001-11-06 12:03:23 +0000 |
commit | a181e61ca0119b8c3fd2daa4b8d23add2cda3ed0 (patch) | |
tree | 57176d5ca8f96008180eac92518791ef22add726 /include/fuse.h | |
parent | 5e183482b09cec20f54ccb44e767a7fab51833e9 (diff) | |
download | libfuse-a181e61ca0119b8c3fd2daa4b8d23add2cda3ed0.tar.gz |
bugfixes
Diffstat (limited to 'include/fuse.h')
-rw-r--r-- | include/fuse.h | 46 |
1 files changed, 27 insertions, 19 deletions
diff --git a/include/fuse.h b/include/fuse.h index bdc96a6..4edb0c7 100644 --- a/include/fuse.h +++ b/include/fuse.h @@ -13,30 +13,38 @@ #include <utime.h> struct fuse; -struct fuse_dh; +typedef struct fuse_dirhandle *fuse_dirh_t; -typedef int (*dirfiller_t) (struct fuse_dh *, const char *, int type); +typedef int (*fuse_dirfil_t) (fuse_dirh_t, const char *, int type); + +struct fuse_cred { + uid_t uid; + gid_t gid; +}; struct fuse_operations { - int (*getattr) (const char *path, struct stat *stbuf); - int (*readlink) (const char *path, char *buf, size_t size); - int (*getdir) (const char *path, struct fuse_dh *h, dirfiller_t filler); - int (*mknod) (const char *path, mode_t mode, dev_t rdev); - int (*mkdir) (const char *path, mode_t mode); - int (*unlink) (const char *path); - int (*rmdir) (const char *path); - int (*symlink) (const char *from, const char *to); - int (*rename) (const char *from, const char *to); - int (*link) (const char *from, const char *to); - int (*chmod) (const char *path, mode_t mode); - int (*chown) (const char *path, uid_t uid, gid_t gid); - int (*truncate) (const char *path, off_t size); - int (*utime) (const char *path, struct utimbuf *buf); - int (*open) (const char *path, int flags); - int (*pread) (const char *path, char *buf, size_t size, off_t offset); + int (*getattr) (struct fuse_cred *, const char *, struct stat *); + int (*readlink) (struct fuse_cred *, const char *, char *, size_t); + int (*getdir) (struct fuse_cred *, const char *, fuse_dirh_t, fuse_dirfil_t); + int (*mknod) (struct fuse_cred *, const char *, mode_t, dev_t); + int (*mkdir) (struct fuse_cred *, const char *, mode_t); + int (*unlink) (struct fuse_cred *, const char *); + int (*rmdir) (struct fuse_cred *, const char *); + int (*symlink) (struct fuse_cred *, const char *, const char *); + int (*rename) (struct fuse_cred *, const char *, const char *); + int (*link) (struct fuse_cred *, const char *, const char *); + int (*chmod) (struct fuse_cred *, const char *, mode_t); + int (*chown) (struct fuse_cred *, const char *, uid_t, gid_t); + int (*truncate) (struct fuse_cred *, const char *, off_t); + int (*utime) (struct fuse_cred *, const char *, struct utimbuf *); + int (*open) (struct fuse_cred *, const char *, int); + int (*read) (struct fuse_cred *, const char *, char *, size_t, off_t); + int (*write) (struct fuse_cred *, const char *, const char *, size_t, off_t); }; -struct fuse *fuse_new(); +#define FUSE_MULTITHREAD (1 << 0) + +struct fuse *fuse_new(int flags); int fuse_mount(struct fuse *f, const char *dir); |