sb->st_mode = S_IFDIR | 00755;
k = get_cgroup_key(controller, cgroup, "tasks");
if (!k) {
- fprintf(stderr, "Failed to find a tasks file for %s\n", cgroup);
sb->st_uid = sb->st_gid = 0;
} else {
- fprintf(stderr, "found a tasks file for %s\n", cgroup);
sb->st_uid = k->uid;
sb->st_gid = k->gid;
}
nih_local char * cgdir = NULL;
nih_local struct cgm_keys *k = NULL;
-fprintf(stderr, "cg_write: starting\n");
-
if (offset)
return -EIO;
return 0;
}
+int cg_chmod(const char *path, mode_t mode)
+{
+}
+
int cg_mkdir(const char *path, mode_t mode)
{
struct fuse_context *fc = fuse_get_context();
return -EINVAL;
}
+int lxcfs_chmod(const char *path, mode_t mode)
+{
+ if (strncmp(path, "/cgroup", 7) == 0)
+ return cg_chmod(path, mode);
+ return -EINVAL;
+}
+
const struct fuse_operations lxcfs_ops = {
.getattr = lxcfs_getattr,
.readlink = NULL,
.symlink = NULL,
.rename = NULL,
.link = NULL,
- .chmod = NULL,
+ .chmod = lxcfs_chmod,
.chown = lxcfs_chown,
.truncate = lxcfs_truncate,
.utime = NULL,