Skip to content

Commit

Permalink
create output on write
Browse files Browse the repository at this point in the history
  • Loading branch information
tbro committed Nov 8, 2023
1 parent 11a5ff3 commit 96dd493
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions rustls-cert-gen/src/cert/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ pub struct PemCertifiedKey {
impl PemCertifiedKey {
pub fn write(&self, dir: &Path, name: &str) -> Result<(), io::Error> {
use std::io::Write;
std::fs::create_dir_all(dir)?;

let key_path = dir.join(format!("{name}.key.pem"));
let mut key_out = File::create(key_path)?;
Expand Down

0 comments on commit 96dd493

Please sign in to comment.