1
Fork 0
mirror of https://github.com/RGBCube/uutils-coreutils synced 2025-07-28 19:47:45 +00:00

csplit: modify failure in opening file error message

This commit is contained in:
Fuad Ismail 2025-01-07 21:45:52 +07:00 committed by Daniel Hofstetter
parent 96929734ea
commit 694298f0d1

View file

@ -585,7 +585,7 @@ pub fn uumain(args: impl uucore::Args) -> UResult<()> {
Ok(csplit(&options, &patterns, stdin.lock())?)
} else {
let file = File::open(file_name)
.map_err_context(|| format!("cannot access {}", file_name.quote()))?;
.map_err_context(|| format!("cannot open {} for reading", file_name.quote()))?;
Ok(csplit(&options, &patterns, BufReader::new(file))?)
}
}