Loading openssl-sys/src/ossl10x.rs +6 −0 Original line number Diff line number Diff line Loading @@ -527,6 +527,12 @@ fn set_id_callback() { #[cfg(not(unix))] fn set_id_callback() {} // macros #[cfg(ossl102)] pub unsafe fn SSL_CTX_set_ecdh_auto(ctx: *mut SSL_CTX, onoff: c_int) -> c_int { ::SSL_CTX_ctrl(ctx, SSL_CTRL_SET_ECDH_AUTO, onoff as c_long, ::std::ptr::null_mut()) as c_int } extern { pub fn BIO_new(type_: *mut BIO_METHOD) -> *mut BIO; pub fn BIO_s_file() -> *mut BIO_METHOD; Loading openssl/src/ssl/mod.rs +1 −5 Original line number Diff line number Diff line Loading @@ -551,11 +551,7 @@ impl SslContextBuilder { #[cfg(all(feature = "v102", ossl102))] pub fn set_ecdh_auto(&mut self, onoff: bool) -> Result<(), ErrorStack> { unsafe { cvt(ffi::SSL_CTX_ctrl(self.as_ptr(), ffi::SSL_CTRL_SET_ECDH_AUTO, onoff as c_long, ptr::null_mut()) as c_int) .map(|_| ()) cvt(ffi::SSL_CTX_set_ecdh_auto(self.as_ptr(), onoff as c_int)).map(|_| ()) } } Loading Loading
openssl-sys/src/ossl10x.rs +6 −0 Original line number Diff line number Diff line Loading @@ -527,6 +527,12 @@ fn set_id_callback() { #[cfg(not(unix))] fn set_id_callback() {} // macros #[cfg(ossl102)] pub unsafe fn SSL_CTX_set_ecdh_auto(ctx: *mut SSL_CTX, onoff: c_int) -> c_int { ::SSL_CTX_ctrl(ctx, SSL_CTRL_SET_ECDH_AUTO, onoff as c_long, ::std::ptr::null_mut()) as c_int } extern { pub fn BIO_new(type_: *mut BIO_METHOD) -> *mut BIO; pub fn BIO_s_file() -> *mut BIO_METHOD; Loading
openssl/src/ssl/mod.rs +1 −5 Original line number Diff line number Diff line Loading @@ -551,11 +551,7 @@ impl SslContextBuilder { #[cfg(all(feature = "v102", ossl102))] pub fn set_ecdh_auto(&mut self, onoff: bool) -> Result<(), ErrorStack> { unsafe { cvt(ffi::SSL_CTX_ctrl(self.as_ptr(), ffi::SSL_CTRL_SET_ECDH_AUTO, onoff as c_long, ptr::null_mut()) as c_int) .map(|_| ()) cvt(ffi::SSL_CTX_set_ecdh_auto(self.as_ptr(), onoff as c_int)).map(|_| ()) } } Loading