• Joe Lee's avatar
    Make HttpClient adapter preserve exception behavior · ea4dc7f0
    Joe Lee authored
    Ideally, the HttpClient/HttpServer adapters should maintain the invariant that
    the behavior of a given client is the same as the behavior of
    newHttpClient(newHttpService(client)).  Prior to this change, the HttpClient
    wrapper lazily called request(), so a client whose request() eagerly threw an
    exception could produce a different exception when called directly versus when
    wrapped -- the laziness allowed additional code to run.  This was particularly
    evident when making a request with a body, since code using a wrapped client
    would be able to set up a subsequent BlockedWrite, eventually resulting in a
    "read end of pipe was aborted" exception instead of the actual exception.
    
    This change makes HttpClientAdapter::request() execute the wrapped request()
    eagerly.
    
    (Note that it partially undoes 90d48343... Hopefully, it preserves the desired
    behavior added there.)
    ea4dc7f0
Name
Last commit
Last update
..
cmake Loading commit data...
ekam-provider Loading commit data...
m4 Loading commit data...
pkgconfig Loading commit data...
samples Loading commit data...
src Loading commit data...
CMakeLists.txt Loading commit data...
LICENSE.txt Loading commit data...
Makefile.am Loading commit data...
Makefile.ekam Loading commit data...
README.txt Loading commit data...
afl-fuzz.sh Loading commit data...
configure.ac Loading commit data...
regenerate-bootstraps.sh Loading commit data...
setup-autotools.sh Loading commit data...
setup-ekam.sh Loading commit data...