diff options
| author | Steven Fackler <[email protected]> | 2014-09-30 02:15:40 -0400 |
|---|---|---|
| committer | Steven Fackler <[email protected]> | 2014-09-30 02:15:40 -0400 |
| commit | 36977c2aa3d761c12912d46e2d3703505eb01f51 (patch) | |
| tree | 12a842f098c7cdbea5190097647666d34eabc093 /src/bio | |
| parent | Merge pull request #53 from vhbit/cert-gen (diff) | |
| parent | single `ffi` module (diff) | |
| download | rust-openssl-36977c2aa3d761c12912d46e2d3703505eb01f51.tar.xz rust-openssl-36977c2aa3d761c12912d46e2d3703505eb01f51.zip | |
Merge pull request #56 from vhbit/single-ffi
Single `ffi` module
Diffstat (limited to 'src/bio')
| -rw-r--r-- | src/bio/mod.rs | 18 |
1 files changed, 1 insertions, 17 deletions
diff --git a/src/bio/mod.rs b/src/bio/mod.rs index f81114de..5c5e8df0 100644 --- a/src/bio/mod.rs +++ b/src/bio/mod.rs @@ -3,6 +3,7 @@ use std::io::{IoResult, IoError, OtherIoError}; use std::io::{Reader, Writer}; use std::ptr; +use ffi; use ssl::error::{SslError}; pub struct MemBio { @@ -84,20 +85,3 @@ impl Writer for MemBio { } } } - -pub mod ffi { - #![allow(non_camel_case_types)] - - use libc::{c_int, c_void}; - - pub type BIO = c_void; - pub type BIO_METHOD = c_void; - - extern "C" { - pub fn BIO_s_mem() -> *const BIO_METHOD; - pub fn BIO_new(type_: *const BIO_METHOD) -> *mut BIO; - pub fn BIO_free_all(a: *mut BIO); - pub fn BIO_read(b: *mut BIO, buf: *mut c_void, len: c_int) -> c_int; - pub fn BIO_write(b: *mut BIO, buf: *const c_void, len: c_int) -> c_int; - } -} |