fix(transport): Fix infinite recursion in poll_ready (#192)
b90c340 (feat(transport): Allow custom IO and UDS example (#184),
2019-12-13) changed the Connector type to be more generic instead of
only allowing the HttpConnector type, during this change the
`Service::poll_ready` impl was changed from calling
`MakeConnection::poll_ready` on `self.http` to `self` resulting in
infinite recursion due to the blanket imple of
`MakeConnection::poll_ready` calling `Service::poll_ready`.
This fixes the bug by calling `MakeConnection::poll_ready` on
`self.inner` instead of `self`.
Fixes #191
This commit is contained in:
committed by
Lucio Franco
parent
3a5c66d5f2
commit
c99d13c6e6
@@ -53,7 +53,7 @@ where
|
||||
Pin<Box<dyn Future<Output = Result<Self::Response, Self::Error>> + Send + 'static>>;
|
||||
|
||||
fn poll_ready(&mut self, cx: &mut Context<'_>) -> Poll<Result<(), Self::Error>> {
|
||||
MakeConnection::poll_ready(self, cx).map_err(Into::into)
|
||||
MakeConnection::poll_ready(&mut self.inner, cx).map_err(Into::into)
|
||||
}
|
||||
|
||||
fn call(&mut self, uri: Uri) -> Self::Future {
|
||||
|
||||
Reference in New Issue
Block a user