aboutsummaryrefslogtreecommitdiff
path: root/openssl/src/bio/mod.rs
diff options
context:
space:
mode:
authorSteven Fackler <[email protected]>2015-07-06 11:09:19 -0700
committerSteven Fackler <[email protected]>2015-07-06 11:09:19 -0700
commit114e8a5a58a8fb3c4cc37391fc2f5a7addd796fc (patch)
treed35618791cfc3bf1815b310639f74185a0d0464d /openssl/src/bio/mod.rs
parentMerge branch 'release-v0.6.3' into release (diff)
parentRelease v0.6.4 (diff)
downloadrust-openssl-0.6.4.tar.xz
rust-openssl-0.6.4.zip
Merge branch 'release-v0.6.4' into releasev0.6.4
Diffstat (limited to 'openssl/src/bio/mod.rs')
-rw-r--r--openssl/src/bio/mod.rs8
1 files changed, 3 insertions, 5 deletions
diff --git a/openssl/src/bio/mod.rs b/openssl/src/bio/mod.rs
index e81694a4..7eea16d8 100644
--- a/openssl/src/bio/mod.rs
+++ b/openssl/src/bio/mod.rs
@@ -73,11 +73,10 @@ impl Read for MemBio {
if ret <= 0 {
let is_eof = unsafe { ffi::BIO_eof(self.bio) };
- if is_eof {
+ if is_eof != 0 {
Ok(0)
} else {
- Err(io::Error::new(io::ErrorKind::Other,
- SslError::get()))
+ Err(io::Error::new(io::ErrorKind::Other, SslError::get()))
}
} else {
Ok(ret as usize)
@@ -93,8 +92,7 @@ impl Write for MemBio {
};
if ret < 0 {
- Err(io::Error::new(io::ErrorKind::Other,
- SslError::get()))
+ Err(io::Error::new(io::ErrorKind::Other, SslError::get()))
} else {
Ok(ret as usize)
}