From 4e54038ffcb40b48d102f751bf8da5e7237e282a Mon Sep 17 00:00:00 2001 From: Steven Fackler Date: Thu, 24 Apr 2014 23:28:20 -0700 Subject: [PATCH] Update for attributes on match arms --- ssl/mod.rs | 11 +---------- 1 file changed, 1 insertion(+), 10 deletions(-) diff --git a/ssl/mod.rs b/ssl/mod.rs index 4564bce9..123ece41 100644 --- a/ssl/mod.rs +++ b/ssl/mod.rs @@ -58,24 +58,15 @@ pub enum SslMethod { } impl SslMethod { - #[cfg(sslv2)] unsafe fn to_raw(&self) -> *ffi::SSL_METHOD { match *self { + #[cfg(sslv2)] Sslv2 => ffi::SSLv2_method(), Sslv3 => ffi::SSLv3_method(), Tlsv1 => ffi::TLSv1_method(), Sslv23 => ffi::SSLv23_method() } } - - #[cfg(not(sslv2))] - unsafe fn to_raw(&self) -> *ffi::SSL_METHOD { - match *self { - Sslv3 => ffi::SSLv3_method(), - Tlsv1 => ffi::TLSv1_method(), - Sslv23 => ffi::SSLv23_method() - } - } } /// Determines the type of certificate verification used