diff options
| author | João Barbosa <[email protected]> | 2019-07-17 15:27:44 +0100 |
|---|---|---|
| committer | João Barbosa <[email protected]> | 2019-07-17 15:32:38 +0100 |
| commit | a981e749e6553487cd48eda28e590f769e81c85c (patch) | |
| tree | d08c59d88e1f8bb9088d9745cc174fe4199dc086 /src/torcontrol.cpp | |
| parent | Merge #16208: wallet: Consume ReserveDestination on successful CreateTransaction (diff) | |
| download | discoin-a981e749e6553487cd48eda28e590f769e81c85c.tar.xz discoin-a981e749e6553487cd48eda28e590f769e81c85c.zip | |
fix: tor: Call event_base_loopbreak from the event's callback
Diffstat (limited to 'src/torcontrol.cpp')
| -rw-r--r-- | src/torcontrol.cpp | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/torcontrol.cpp b/src/torcontrol.cpp index a1c730ba0..3f40785c2 100644 --- a/src/torcontrol.cpp +++ b/src/torcontrol.cpp @@ -759,7 +759,9 @@ void InterruptTorControl() { if (gBase) { LogPrintf("tor: Thread interrupt\n"); - event_base_loopbreak(gBase); + event_base_once(gBase, -1, EV_TIMEOUT, [](evutil_socket_t, short, void*) { + event_base_loopbreak(gBase); + }, nullptr, nullptr); } } |