Page MenuHomePhabricator

D9948.diff
No OneTemporary

D9948.diff

diff --git a/src/bitcoin-cli.cpp b/src/bitcoin-cli.cpp
--- a/src/bitcoin-cli.cpp
+++ b/src/bitcoin-cli.cpp
@@ -959,9 +959,14 @@
* @returns getnewaddress response as a UniValue object.
*/
static UniValue GetNewAddress() {
+ std::optional<std::string> wallet_name{};
+ if (gArgs.IsArgSet("-rpcwallet")) {
+ wallet_name = gArgs.GetArg("-rpcwallet", "");
+ }
std::unique_ptr<BaseRequestHandler> rh{
std::make_unique<DefaultRequestHandler>()};
- return ConnectAndCallRPC(rh.get(), "getnewaddress", /* args=*/{});
+ return ConnectAndCallRPC(rh.get(), "getnewaddress", /* args=*/{},
+ wallet_name);
}
/**

File Metadata

Mime Type
text/plain
Expires
Sat, Mar 1, 12:11 (5 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
5187802
Default Alt Text
D9948.diff (672 B)

Event Timeline