Skip to content

Commit

Permalink
Cargo fmt
Browse files Browse the repository at this point in the history
  • Loading branch information
swenson authored and jhand2 committed Feb 3, 2025
1 parent 3870341 commit 872cb3c
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 3 deletions.
4 changes: 3 additions & 1 deletion dpe/build.rs
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,9 @@ fn main() {
let max_handles_str = format!("pub const MAX_HANDLES: usize = {};", arbitrary_max_handles);

let dest_path = PathBuf::from(&dest_path);
if dest_path.exists() && std::fs::read_to_string(&dest_path).unwrap_or_default() != max_handles_str {
if dest_path.exists()
&& std::fs::read_to_string(&dest_path).unwrap_or_default() != max_handles_str
{
std::fs::write(&dest_path, max_handles_str).unwrap();
}
println!("cargo:rerun-if-changed={}", dest_path.display());
Expand Down
6 changes: 4 additions & 2 deletions dpe/src/x509.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1590,7 +1590,7 @@ impl CertWriter<'_> {
/// AuthorityKeyIdentifier ::= SEQUENCE {
/// keyIdentifier [0] KeyIdentifier OPTIONAL,
/// authorityCertIssuer [1] GeneralNames OPTIONAL,
/// authorityCertSerialNumber [2] CertificateSerialNumber OPTIONAL
/// authorityCertSerialNumber [2] CertificateSerialNumber OPTIONAL
/// }
fn encode_authority_key_identifier_extension(
&mut self,
Expand Down Expand Up @@ -2994,7 +2994,9 @@ pub(crate) mod tests {
_ => (),
}

if let Err(_) = cert.get_extension_unique(&oid!(2.5.29 .35)) { panic!("multiple authority key identifier extensions found") }
if let Err(_) = cert.get_extension_unique(&oid!(2.5.29 .35)) {
panic!("multiple authority key identifier extensions found")
}

match cert.subject_alternative_name() {
Ok(Some(ext)) => {
Expand Down

0 comments on commit 872cb3c

Please sign in to comment.