get_error -> error
This commit is contained in:
parent
a0a6c03d74
commit
79602b6af4
|
|
@ -310,7 +310,7 @@ run_test!(verify_callback_load_certs, |method, stream| {
|
|||
run_test!(verify_trusted_get_error_ok, |method, stream| {
|
||||
let mut ctx = SslContext::new(method).unwrap();
|
||||
ctx.set_verify_callback(SSL_VERIFY_PEER, |_, x509_ctx| {
|
||||
assert!(x509_ctx.get_error().is_none());
|
||||
assert!(x509_ctx.error().is_none());
|
||||
true
|
||||
});
|
||||
|
||||
|
|
@ -324,7 +324,7 @@ run_test!(verify_trusted_get_error_ok, |method, stream| {
|
|||
run_test!(verify_trusted_get_error_err, |method, stream| {
|
||||
let mut ctx = SslContext::new(method).unwrap();
|
||||
ctx.set_verify_callback(SSL_VERIFY_PEER, |_, x509_ctx| {
|
||||
assert!(x509_ctx.get_error().is_some());
|
||||
assert!(x509_ctx.error().is_some());
|
||||
false
|
||||
});
|
||||
|
||||
|
|
|
|||
|
|
@ -83,7 +83,7 @@ impl X509StoreContext {
|
|||
X509StoreContext { ctx: ctx }
|
||||
}
|
||||
|
||||
pub fn get_error(&self) -> Option<X509ValidationError> {
|
||||
pub fn error(&self) -> Option<X509ValidationError> {
|
||||
let err = unsafe { ffi::X509_STORE_CTX_get_error(self.ctx) };
|
||||
X509ValidationError::from_raw(err)
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue