File tree Expand file tree Collapse file tree 1 file changed +18
-0
lines changed Expand file tree Collapse file tree 1 file changed +18
-0
lines changed Original file line number Diff line number Diff line change @@ -314,6 +314,24 @@ impl ConnectConfiguration {
314314 pub fn set_alps_use_new_codepoint ( & mut self , use_new : bool ) {
315315 unsafe { ffi:: SSL_set_alps_use_new_codepoint ( self . as_ptr ( ) , use_new as _ ) }
316316 }
317+
318+ /// Sets the SSL options.
319+ ///
320+ /// # Arguments
321+ ///
322+ /// * `options` - An `SslOptions` bitmask representing the options to set.
323+ ///
324+ /// # Returns
325+ ///
326+ /// * `Result<(), ErrorStack>` - Returns `Ok(())` if the operation is successful, otherwise returns an `ErrorStack`.
327+ ///
328+ /// # Safety
329+ ///
330+ /// This function is unsafe because it calls an FFI function.
331+ #[ corresponds( SSL_set_options ) ]
332+ pub fn set_options ( & mut self , options : SslOptions ) -> Result < ( ) , ErrorStack > {
333+ unsafe { cvt ( ffi:: SSL_set_options ( self . as_ptr ( ) , options. bits ( ) ) as _ ) . map ( |_| ( ) ) }
334+ }
317335}
318336
319337impl Deref for ConnectConfiguration {
You can’t perform that action at this time.
0 commit comments