We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 87c9b49 commit d15bb53Copy full SHA for d15bb53
git-config/src/values.rs
@@ -299,6 +299,7 @@ quick_error! {
299
}
300
Pwd {
301
display("User home info missing")
302
+ from()
303
304
Unsupported {
305
display("Not available on this platform")
@@ -369,7 +370,8 @@ impl Path<'_> {
369
370
.ok_or(PathError::Missing { what: "/" })?;
371
let (username, val) = val.split_at(i);
372
let username = std::str::from_utf8(username)?;
- let home = Passwd::from_name(username)?
373
+ let home = Passwd::from_name(username)
374
+ .map_err(|_| PathError::Pwd)
375
.ok_or(PathError::Missing { what: "pwd user info" })?
376
.dir;
377
let mut expanded = home.as_bytes().to_owned();
0 commit comments