fix(http): stackoverflow in Conn::ready

I've had a couple of instances during stress testing now where
Conn::ready would overflow its stack due to recursing on itself. This
moves subsequent calls to ready() into a loop outside the function.
This commit is contained in:
Joe Wilm
2016-10-06 17:23:18 -07:00
parent 8672ec5a36
commit c32d0e9adf
4 changed files with 58 additions and 20 deletions

View File

@@ -17,7 +17,7 @@ use version::HttpVersion::{Http10, Http11};
#[cfg(feature = "serde-serialization")]
use serde::{Deserialize, Deserializer, Serialize, Serializer};
pub use self::conn::{Conn, MessageHandler, MessageHandlerFactory, Seed, Key};
pub use self::conn::{Conn, MessageHandler, MessageHandlerFactory, Seed, Key, ReadyResult};
mod buffer;
pub mod channel;