diff options
author | Wladimir J. van der Laan <laanwj@gmail.com> | 2016-12-19 12:38:35 +0100 |
---|---|---|
committer | Wladimir J. van der Laan <laanwj@gmail.com> | 2016-12-19 12:40:01 +0100 |
commit | 7f72568e6b15fc139323fb200591a50762f6df0b (patch) | |
tree | 85a19f00ca5bd8c88874d3f162d5ca84ac2c95d9 /src/qt | |
parent | a336d13a587c46470fd6671d558198f299f04a8d (diff) | |
parent | 749be013f5cba0bbb01f1f89df77106aea5a4cc1 (diff) | |
download | bitcoin-7f72568e6b15fc139323fb200591a50762f6df0b.tar.xz |
Merge #9236: Fix races for strMiscWarning and fLargeWork*Found, make QT runawayException use GetWarnings
749be01 Move GetWarnings() into its own file. (Gregory Maxwell)
e3ba0ef Eliminate data races for strMiscWarning and fLargeWork*Found. (Gregory Maxwell)
c63198f Make QT runawayException call GetWarnings instead of directly access strMiscWarning. (Gregory Maxwell)
Diffstat (limited to 'src/qt')
-rw-r--r-- | src/qt/bitcoin.cpp | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/src/qt/bitcoin.cpp b/src/qt/bitcoin.cpp index 4f48e21a22..cfd0955a74 100644 --- a/src/qt/bitcoin.cpp +++ b/src/qt/bitcoin.cpp @@ -30,6 +30,7 @@ #include "scheduler.h" #include "ui_interface.h" #include "util.h" +#include "warnings.h" #ifdef ENABLE_WALLET #include "wallet/wallet.h" @@ -260,7 +261,7 @@ BitcoinCore::BitcoinCore(): void BitcoinCore::handleRunawayException(const std::exception *e) { PrintExceptionContinue(e, "Runaway exception"); - Q_EMIT runawayException(QString::fromStdString(strMiscWarning)); + Q_EMIT runawayException(QString::fromStdString(GetWarnings("gui"))); } void BitcoinCore::initialize() @@ -691,10 +692,10 @@ int main(int argc, char *argv[]) app.exec(); } catch (const std::exception& e) { PrintExceptionContinue(&e, "Runaway exception"); - app.handleRunawayException(QString::fromStdString(strMiscWarning)); + app.handleRunawayException(QString::fromStdString(GetWarnings("gui"))); } catch (...) { PrintExceptionContinue(NULL, "Runaway exception"); - app.handleRunawayException(QString::fromStdString(strMiscWarning)); + app.handleRunawayException(QString::fromStdString(GetWarnings("gui"))); } return app.getReturnValue(); } |