diff options
| author | mtg0001 <106211915+mtg0001@users.noreply.github.com> | 2026-08-03 10:43:42 -0300 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2026-08-03 10:43:42 -0300 |
| commit | 57441faffb02f4f2eea37d31b29728de25f18bef (patch) | |
| tree | edade03dddf472790e8bc7e3bc52d3e8f8eac87b /src/main_gui.cpp | |
| parent | 5e37647023463cec4331dc48dc360ba60b22c888 (diff) | |
Add wallet recovery balance audit (#117)
Co-authored-by: Gilcimar Duarte <ti@gpm.infra>
Diffstat (limited to 'src/main_gui.cpp')
| -rw-r--r-- | src/main_gui.cpp | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/src/main_gui.cpp b/src/main_gui.cpp index 32fcdef..1b72813 100644 --- a/src/main_gui.cpp +++ b/src/main_gui.cpp | |||
| @@ -93,7 +93,10 @@ static void PrintUsage() | |||
| 93 | printf(" /restoredepth=N (with /restorephrase: derive at least N\n"); | 93 | printf(" /restoredepth=N (with /restorephrase: derive at least N\n"); |
| 94 | printf(" addresses before giving up)\n"); | 94 | printf(" addresses before giving up)\n"); |
| 95 | printf(" /showderived=N (list the first N addresses a phrase\n"); | 95 | printf(" /showderived=N (list the first N addresses a phrase\n"); |
| 96 | printf(" produces, without installing it)\n"); | 96 | printf(" installed in this wallet derives)\n"); |
| 97 | printf(" /recoveryaudit (show how much spendable balance is\n"); | ||
| 98 | printf(" covered by the recovery phrase;\n"); | ||
| 99 | printf(" exits 2 when wallet.dat is still needed)\n"); | ||
| 97 | printf(" /rescan (walk the chain for coins this wallet owns\n"); | 100 | printf(" /rescan (walk the chain for coins this wallet owns\n"); |
| 98 | printf(" but never recorded, then exit)\n"); | 101 | printf(" but never recorded, then exit)\n"); |
| 99 | printf("\n"); | 102 | printf("\n"); |
| @@ -385,6 +388,13 @@ int main(int argc, char* argv[]) | |||
| 385 | return nRet; | 388 | return nRet; |
| 386 | } | 389 | } |
| 387 | 390 | ||
| 391 | if (arg(argc,argv,"/recoveryaudit") || arg(argc,argv,"-recoveryaudit")) | ||
| 392 | { | ||
| 393 | int nRet = CmdRecoveryAudit(); | ||
| 394 | DBFlush(true); | ||
| 395 | return nRet; | ||
| 396 | } | ||
| 397 | |||
| 388 | if (arg(argc,argv,"/newphrase") || arg(argc,argv,"-newphrase")) | 398 | if (arg(argc,argv,"/newphrase") || arg(argc,argv,"-newphrase")) |
| 389 | { | 399 | { |
| 390 | int nRet = CmdNewPhrase(); | 400 | int nRet = CmdNewPhrase(); |