redbear: apply readonly-live-media patch, add author attribution, use local redox-scheme path
This commit is contained in:
+3
-4
@@ -5,7 +5,7 @@ repository = "https://gitlab.redox-os.org/redox-os/redoxfs"
|
||||
version = "0.9.1+rb0.2.5"
|
||||
license-file = "LICENSE"
|
||||
readme = "README.md"
|
||||
authors = ["Jeremy Soller <jackpot51@gmail.com>"]
|
||||
authors = ["Jeremy Soller <jackpot51@gmail.com>", "vasilito <adminpupkin@gmail.com>"]
|
||||
edition = "2021"
|
||||
|
||||
[lib]
|
||||
@@ -58,7 +58,6 @@ parse-size = { version = "1", optional = true }
|
||||
range-tree = { version = "0.1", optional = true }
|
||||
redox_syscall = { path = "../syscall" }
|
||||
seahash = { version = "4.1.0", default-features = false }
|
||||
smallvec = { version = "1.15.2", optional = true }
|
||||
termion = { version = "4", optional = true }
|
||||
uuid = { version = "1.4", default-features = false }
|
||||
xts-mode = { version = "0.5", default-features = false }
|
||||
@@ -80,7 +79,6 @@ std = [
|
||||
"uuid/v4",
|
||||
"redox_syscall/std",
|
||||
"redox-scheme",
|
||||
"smallvec",
|
||||
]
|
||||
|
||||
[target.'cfg(not(target_os = "redox"))'.dependencies]
|
||||
@@ -88,7 +86,7 @@ fuser = { version = "0.16", optional = true }
|
||||
|
||||
[target.'cfg(target_os = "redox")'.dependencies]
|
||||
libredox = { path = "../libredox", optional = true }
|
||||
redox-path = "0.4.0"
|
||||
redox-path = "0.3.0"
|
||||
redox-scheme = { path = "../redox-scheme", optional = true }
|
||||
|
||||
[lints.rust]
|
||||
@@ -100,3 +98,4 @@ assert_cmd = "2.0.17"
|
||||
[patch.crates-io]
|
||||
redox_syscall = { path = "../syscall" }
|
||||
libredox = { path = "../libredox" }
|
||||
redox-scheme = { path = "../redox-scheme" }
|
||||
|
||||
@@ -43,10 +43,12 @@ impl<T> ResultExt for std::io::Result<T> {
|
||||
|
||||
impl DiskFile {
|
||||
pub fn open(path: impl AsRef<Path>) -> Result<DiskFile> {
|
||||
let path = path.as_ref();
|
||||
let file = OpenOptions::new()
|
||||
.read(true)
|
||||
.write(true)
|
||||
.open(path)
|
||||
.or_else(|_| OpenOptions::new().read(true).open(path))
|
||||
.or_eio()?;
|
||||
Ok(DiskFile { file })
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user