diff --git a/Cargo.lock b/Cargo.lock index d88a77e..719d80e 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -13,7 +13,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" [[package]] name = "bitflags" -version = "1.0.0" +version = "1.0.1" source = "registry+https://github.com/rust-lang/crates.io-index" [[package]] @@ -35,10 +35,10 @@ name = "kernel" version = "0.1.0" dependencies = [ "alloc_kernel 0.1.0", - "bitflags 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)", + "bitflags 1.0.1 (registry+https://github.com/rust-lang/crates.io-index)", "goblin 0.0.10 (registry+https://github.com/rust-lang/crates.io-index)", "raw-cpuid 3.0.0 (registry+https://github.com/rust-lang/crates.io-index)", - "redox_syscall 0.1.31", + "redox_syscall 0.1.32", "spin 0.4.6 (registry+https://github.com/rust-lang/crates.io-index)", "x86 0.7.2 (registry+https://github.com/rust-lang/crates.io-index)", ] @@ -75,7 +75,7 @@ dependencies = [ [[package]] name = "redox_syscall" -version = "0.1.31" +version = "0.1.32" [[package]] name = "scroll" @@ -97,7 +97,7 @@ dependencies = [ [metadata] "checksum bitflags 0.7.0 (registry+https://github.com/rust-lang/crates.io-index)" = "aad18937a628ec6abcd26d1489012cc0e18c21798210f491af69ded9b881106d" -"checksum bitflags 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)" = "f5cde24d1b2e2216a726368b2363a273739c91f4e3eb4e0dd12d672d396ad989" +"checksum bitflags 1.0.1 (registry+https://github.com/rust-lang/crates.io-index)" = "b3c30d3802dfb7281680d6285f2ccdaa8c2d8fee41f93805dba5c4cf50dc23cf" "checksum gcc 0.3.54 (registry+https://github.com/rust-lang/crates.io-index)" = "5e33ec290da0d127825013597dbdfc28bee4964690c7ce1166cbc2a7bd08b1bb" "checksum goblin 0.0.10 (registry+https://github.com/rust-lang/crates.io-index)" = "81af14056c25d33759862c5ae2035452acb1255bfb1b16db57819f183921e259" "checksum linked_list_allocator 0.4.1 (git+https://github.com/redox-os/linked-list-allocator.git)" = "" diff --git a/src/scheme/user.rs b/src/scheme/user.rs index ed2b06c..31b69be 100644 --- a/src/scheme/user.rs +++ b/src/scheme/user.rs @@ -280,6 +280,16 @@ impl Scheme for UserScheme { inner.call(SYS_LSEEK, file, position, whence) } + fn fchmod(&self, file: usize, mode: u16) -> Result { + let inner = self.inner.upgrade().ok_or(Error::new(ENODEV))?; + inner.call(SYS_FCHMOD, file, mode as usize, 0) + } + + fn fchown(&self, file: usize, uid: u32, gid: u32) -> Result { + let inner = self.inner.upgrade().ok_or(Error::new(ENODEV))?; + inner.call(SYS_FCHOWN, file, uid as usize, gid as usize) + } + fn fcntl(&self, file: usize, cmd: usize, arg: usize) -> Result { let inner = self.inner.upgrade().ok_or(Error::new(ENODEV))?; inner.call(SYS_FCNTL, file, cmd, arg) diff --git a/syscall b/syscall index 71c51bd..3c76573 160000 --- a/syscall +++ b/syscall @@ -1 +1 @@ -Subproject commit 71c51bdbbbac3500074a8ed15a2912f38ee7a0f6 +Subproject commit 3c765737a5e9146ffb241c67050c1be9bf28aab7