Browse Source

修改判断绝对路径失败问题 (#9)

GnoCiYeH 1 year ago
parent
commit
b7c9cf0322
1 changed files with 1 additions and 1 deletions
  1. 1 1
      src/std/path.rs

+ 1 - 1
src/std/path.rs

@@ -2125,7 +2125,7 @@ impl Path {
             // FIXME: Allow Redox prefixes
             self.has_root() || has_redox_scheme(self.as_u8_slice())
         } else {
-            self.has_root() && (cfg!(any(unix, target_os = "wasi")) || self.prefix().is_some())
+            self.has_root() && (cfg!(any(unix, target_os = "wasi", target_os = "dragonos")) || self.prefix().is_some())
         }
     }