Преглед на файлове

增加mknod系统调用 (#19)

GnoCiYeH преди 1 година
родител
ревизия
66739c1b10
променени са 2 файла, в които са добавени 2 реда и са изтрити 3 реда
  1. 1 1
      Cargo.toml
  2. 1 2
      src/platform/dragonos/mod.rs

+ 1 - 1
Cargo.toml

@@ -42,7 +42,7 @@ sc = "0.2.3"
 
 [target.'cfg(target_os = "dragonos")'.dependencies]
 # Development
-dragonos-dsc = { git = "https://github.com/DragonOS-Community/dsc.git", rev = "d6e4fd8" }
+dragonos-dsc = { git = "https://git.mirrors.dragonos.org/DragonOS-Community/dragonos-dsc.git", rev = "539a8cdce8" }
 
 [target.'cfg(target_os = "redox")'.dependencies]
 redox_syscall = "0.3"

+ 1 - 2
src/platform/dragonos/mod.rs

@@ -353,8 +353,7 @@ impl Pal for Sys {
     }
 
     fn mkfifo(path: &CStr, mode: mode_t) -> c_int {
-        // e(unsafe { syscall!(MKNODAT, AT_FDCWD, path.as_ptr(), mode | S_IFIFO, 0) }) as c_int
-        unimplemented!()
+        e(unsafe { syscall!(SYS_MKNOD, path.as_ptr(), mode | S_IFIFO, 0) }) as c_int
     }
 
     unsafe fn mlock(addr: *const c_void, len: usize) -> c_int {