-
Notifications
You must be signed in to change notification settings - Fork 299
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Audit use of unsafe in uri/authority.rs (#414)
* Add unit test for rejecting invalid UTF-8 * Add Authority::from_static() test * Refactor uri::Authority Extract the common code from three ways of creating an Authority into a private create_authority() function. * Add comments to explain the safety of Authority The comments describe the preconditions and postconditions that together ensure that the one use of 'unsafe' in uri/authority.rs is sound. * Fix typo
- Loading branch information
Showing
2 changed files
with
63 additions
and
31 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters