Skip to content

Commit 3e4fbdb

Browse files
author
Georg Weisert
committed
linting
1 parent a53177e commit 3e4fbdb

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

openssl/src/x509/mod.rs

+6-1
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,6 @@ use crate::ssl::SslRef;
3939
use crate::stack::{Stack, StackRef, Stackable};
4040
use crate::string::OpensslString;
4141
use crate::util::{ForeignTypeExt, ForeignTypeRefExt};
42-
use crate::x509::extension::AuthorityKeyIdentifier;
4342
use crate::{cvt, cvt_n, cvt_p, cvt_p_const};
4443
use openssl_macros::corresponds;
4544

@@ -1869,15 +1868,21 @@ impl X509Crl {
18691868
ffi::d2i_X509_CRL
18701869
}
18711870

1871+
#[cfg(ossl110)]
18721872
const X509_VERSION_3: i32 = 2;
1873+
#[cfg(ossl110)]
18731874
const X509_CRL_VERSION_2: i32 = 1;
18741875

1876+
// if not cfg(ossl110) issuer_cert is unused
1877+
#[allow(unused_variables)]
18751878
pub fn new(issuer_cert: &X509, conf: Option<&ConfRef>) -> Result<Self, ErrorStack> {
18761879
unsafe {
18771880
let crl = Self(cvt_p(ffi::X509_CRL_new())?);
18781881

18791882
#[cfg(ossl110)]
18801883
if issuer_cert.version() >= Self::X509_VERSION_3 {
1884+
use crate::x509::extension::AuthorityKeyIdentifier;
1885+
18811886
#[cfg(any(ossl110, libressl251, boringssl))]
18821887
{
18831888
// "if present, MUST be v2" (source: RFC 5280, page 55)

0 commit comments

Comments
 (0)