Beispiel #1
0
static int
volicon_open(const char *path, struct fuse_file_info *fi)
{
    if (volicon_is_a_magic_file(path)) {
        if (fi && ((fi->flags & O_ACCMODE) != O_RDONLY)) {
            return -EACCES;
        }

        return 0;
    }

    return fuse_fs_open(volicon_get()->next, path, fi);
}
Beispiel #2
0
static int
volicon_access(const char *path, int mask)
{
	if (volicon_is_a_magic_file(path)) {
		if ((mask & W_OK) || (mask & X_OK)) {
			return -EACCES;
		}

		return 0;
	}

	return fuse_fs_access(volicon_get()->next, path, mask);
}
Beispiel #3
0
static int
volicon_getxtimes(const char *path, struct timespec *bkuptime,
                  struct timespec *crtime)
{
    if (volicon_is_a_magic_file(path)) {
        bkuptime->tv_sec = 0;
        bkuptime->tv_nsec = 0;
        crtime->tv_sec = 0;
        crtime->tv_nsec = 0;
        return 0;
    }

    return fuse_fs_getxtimes(volicon_get()->next, path, bkuptime, crtime);
}