diff options
| author | Daniel Kraft <[email protected]> | 2018-07-23 14:43:45 +0200 |
|---|---|---|
| committer | Daniel Kraft <[email protected]> | 2018-07-23 15:44:58 +0200 |
| commit | 64b9f27e0e46142d01ed5070c544ca7a98183d56 (patch) | |
| tree | eec10f66767708d08a339c2bbbff8b2a6e8d9267 /src/httpserver.cpp | |
| parent | Merge #13719: Avoid creating a temporary vector for size-prefixed elements (diff) | |
| download | discoin-64b9f27e0e46142d01ed5070c544ca7a98183d56.tar.xz discoin-64b9f27e0e46142d01ed5070c544ca7a98183d56.zip | |
Skip is_closing() check when not available.
https://github.com/bitcoin/bitcoin/pull/13715 introduced a new check
for _transport.is_closing() in mininode's P2PConnection's. This function
is only available from Python 3.4.4, though, while Bitcoin is supposed
to support all Python 3.4 versions.
In this change, we make the check conditional on is_closing() being
available. If it is not, then we revert to the behaviour before the
check was introduced; this means that
https://github.com/bitcoin/bitcoin/issues/13579 is not fixed for old
systems, but at least the tests work as they used to do before.
This includes a small refactoring from a one-line lambda to an
inline function, because this makes the code easier to read with more
and more conditions being added.
Fixes https://github.com/bitcoin/bitcoin/issues/13745.
Diffstat (limited to 'src/httpserver.cpp')
0 files changed, 0 insertions, 0 deletions