HomePhabricator

wallet: Display non-HD error on first run

Description

wallet: Display non-HD error on first run

Summary:

On current master a fresh wallet created with -usehd=0 is silently
created as HD wallet.
An error should be displayed on the first run.

Also, this restores a test that was removed in c22a53c

Fixes: #11313

Backport of core PR11307
https://github.com/bitcoin/bitcoin/pull/11307/files

Test Plan:

./test/functional/test_runner.py wallet_hd

mkdir /tmp/wallet
./src/bitcoind -walletdir=/tmp/wallet -usehd=0

Should return an init error:

Error: Error creating : You can't create non-HD wallets with this
version.

Reviewers: #bitcoin_abc, deadalnix

Reviewed By: #bitcoin_abc, deadalnix

Differential Revision: https://reviews.bitcoinabc.org/D3150

Details

Provenance
MarcoFalke <falke.marco@gmail.com>Authored on Sep 12 2017, 10:44
FabienCommitted on May 29 2019, 21:24
jasonbcoxPushed on May 29 2019, 23:04
Reviewer
Restricted Project
Differential Revision
D3150: wallet: Display non-HD error on first run
Parents
rSTAGINGc1f5ea0843e2: Merge #10056: [zmq] Call va_end() on va_start()ed args.
Branches
Unknown
Tags
Unknown
References
tag: phabricator/diff/8993, tag: phabricator/diff/8992, tag: phabricator/base/9004