From 119b0f85e2c8b9729228aad5d946144d57ad0f5b Mon Sep 17 00:00:00 2001 From: Pieter Wuille Date: Tue, 19 Sep 2017 18:12:25 -0700 Subject: Split key_io (address/key encodings) off from base58 --- src/Makefile.am | 2 + src/base58.cpp | 214 ----------------------------------- src/base58.h | 23 +--- src/bitcoin-tx.cpp | 2 +- src/core_write.cpp | 2 +- src/httprpc.cpp | 2 +- src/key_io.cpp | 223 +++++++++++++++++++++++++++++++++++++ src/key_io.h | 29 +++++ src/qt/addresstablemodel.cpp | 3 +- src/qt/bitcoinaddressvalidator.cpp | 2 +- src/qt/coincontroldialog.cpp | 1 + src/qt/guiutil.cpp | 3 + src/qt/paymentrequestplus.cpp | 1 + src/qt/paymentrequestplus.h | 3 +- src/qt/paymentserver.cpp | 2 +- src/qt/sendcoinsdialog.cpp | 2 +- src/qt/signverifymessagedialog.cpp | 2 +- src/qt/test/paymentservertests.cpp | 1 + src/qt/test/wallettests.cpp | 1 + src/qt/transactiondesc.cpp | 2 +- src/qt/transactionrecord.cpp | 2 +- src/qt/walletmodel.cpp | 2 +- src/qt/walletmodel.h | 5 + src/rpc/mining.cpp | 2 +- src/rpc/misc.cpp | 2 +- src/rpc/rawtransaction.cpp | 2 +- src/rpc/server.cpp | 2 +- src/rpc/util.cpp | 2 +- src/test/base58_tests.cpp | 1 + src/test/bip32_tests.cpp | 2 +- src/test/bloom_tests.cpp | 2 +- src/test/key_tests.cpp | 2 +- src/test/rpc_tests.cpp | 2 +- src/wallet/rpcdump.cpp | 2 +- src/wallet/rpcwallet.cpp | 2 +- src/wallet/wallet.cpp | 2 +- src/wallet/walletdb.cpp | 2 +- 37 files changed, 295 insertions(+), 261 deletions(-) create mode 100644 src/key_io.cpp create mode 100644 src/key_io.h (limited to 'src') diff --git a/src/Makefile.am b/src/Makefile.am index ac822d6c5e..a213924a5f 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -105,6 +105,7 @@ BITCOIN_CORE_H = \ indirectmap.h \ init.h \ key.h \ + key_io.h \ keystore.h \ dbwrapper.h \ limitedmap.h \ @@ -327,6 +328,7 @@ libbitcoin_common_a_SOURCES = \ core_read.cpp \ core_write.cpp \ key.cpp \ + key_io.cpp \ keystore.cpp \ netaddress.cpp \ netbase.cpp \ diff --git a/src/base58.cpp b/src/base58.cpp index b2c3161d14..982e123a1d 100644 --- a/src/base58.cpp +++ b/src/base58.cpp @@ -4,20 +4,12 @@ #include -#include #include -#include