aboutsummaryrefslogtreecommitdiff
path: root/src/qt
diff options
context:
space:
mode:
authorWladimir J. van der Laan <laanwj@protonmail.com>2020-03-25 20:11:40 +0100
committerWladimir J. van der Laan <laanwj@protonmail.com>2020-03-25 20:11:47 +0100
commit2e97d8001705214b6b915b61a2c9c34832b85323 (patch)
tree96ebdf569fe04d9945475cbd04b84a115769c787 /src/qt
parent7c942250264e75957d7737ff0d2f5c72e0e19a42 (diff)
parentd056df033a1e88554f7cc39dd709a87b17cb49df (diff)
downloadbitcoin-2e97d8001705214b6b915b61a2c9c34832b85323.tar.xz
Merge #18134: Replace std::to_string with locale-independent alternative
d056df033a1e88554f7cc39dd709a87b17cb49df Replace std::to_string with locale-independent alternative (Ben Woosley) Pull request description: Addresses #17866 following practicalswift's suggestion: https://github.com/bitcoin/bitcoin/issues/17866#issuecomment-584287299 ~Used ::ToString to avoid aliasing issues. Left uses in QT and test.~ ACKs for top commit: practicalswift: ACK d056df033a1e88554f7cc39dd709a87b17cb49df laanwj: ACK d056df033a1e88554f7cc39dd709a87b17cb49df Tree-SHA512: 9e6966a9cdd14f4a1a40d9f0fa7c402aed22b2f1ad8681708e22b050d51a91c5d62220a9ec4c425be2d57acf5c964fca87a5e981b5cbff048bc3b6720dae92b7
Diffstat (limited to 'src/qt')
-rw-r--r--src/qt/optionsmodel.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/qt/optionsmodel.cpp b/src/qt/optionsmodel.cpp
index 977076c4c2..58a7591c95 100644
--- a/src/qt/optionsmodel.cpp
+++ b/src/qt/optionsmodel.cpp
@@ -17,6 +17,7 @@
#include <net.h>
#include <netbase.h>
#include <txdb.h> // for -dbcache defaults
+#include <util/string.h>
#include <QDebug>
#include <QSettings>
@@ -241,7 +242,7 @@ void OptionsModel::SetPruneEnabled(bool prune, bool force)
QSettings settings;
settings.setValue("bPrune", prune);
const int64_t prune_target_mib = PruneGBtoMiB(settings.value("nPruneSize").toInt());
- std::string prune_val = prune ? std::to_string(prune_target_mib) : "0";
+ std::string prune_val = prune ? ToString(prune_target_mib) : "0";
if (force) {
m_node.forceSetArg("-prune", prune_val);
return;