diff options
author | WATANABE Yuki <magicant@wonderwand.net> | 2022-09-11 23:01:08 +0900 |
---|---|---|
committer | WATANABE Yuki <magicant@wonderwand.net> | 2022-09-11 23:07:34 +0900 |
commit | 4d38456cab60843d212a62af7066ceac7bc6011e (patch) | |
tree | 7c1e08c556ec4f499387b1b45de627b2ff38e42a /CHANGELOG.md | |
parent | 1eb589f26fe4b56ce799e05d3b5fb527729cffdf (diff) | |
download | nix-4d38456cab60843d212a62af7066ceac7bc6011e.zip |
Handle unacceptable name gracefully in {User,Group}::from_name
Calling `unwrap` on the result of `CString::new` may cause the current
thread to panic, which is a bit surprising undocumented behavior. It
would be more reasonable to treat the erroneous name as a non-existing
user or group.
Diffstat (limited to 'CHANGELOG.md')
-rw-r--r-- | CHANGELOG.md | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/CHANGELOG.md b/CHANGELOG.md index 9aabc244..63cea70d 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -20,6 +20,9 @@ This project adheres to [Semantic Versioning](https://semver.org/). - Fix microsecond calculation for `TimeSpec`. ([#1801](https://github.com/nix-rust/nix/pull/1801)) +- Fix `User::from_name` and `Group::from_name` panicking + when given a name containing a nul. + ([#1815](https://github.com/nix-rust/nix/pull/1815)) ### Removed |