Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: bitcoin/bitcoin
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: master
Choose a base ref
...
head repository: jackjack-jj/bitcoin
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: master
Choose a head ref
Can’t automatically merge. Don’t worry, you can still create the pull request.
  • 1 commit
  • 2 files changed
  • 1 contributor

Commits on Jul 24, 2011

  1. Add -wallet option

    jackjack committed Jul 24, 2011
    Copy the full SHA
    ab0c48a View commit details
Showing with 5 additions and 3 deletions.
  1. +3 −2 src/init.cpp
  2. +2 −1 src/uibase.cpp
5 changes: 3 additions & 2 deletions src/init.cpp
Original file line number Diff line number Diff line change
@@ -166,6 +166,7 @@ bool AppInit2(int argc, char* argv[])
" bitcoin [options] help \t\t " + _("List commands\n") +
" bitcoin [options] help <command> \t\t " + _("Get help for a command\n") +
_("Options:\n") +
" -wallet=<file> \t\t " + _("Specify wallet file (default: wallet.dat)\n") +
" -conf=<file> \t\t " + _("Specify configuration file (default: bitcoin.conf)\n") +
" -pid=<file> \t\t " + _("Specify pid file (default: bitcoind.pid)\n") +
" -gen \t\t " + _("Generate coins\n") +
@@ -386,7 +387,7 @@ bool AppInit2(int argc, char* argv[])
printf("Loading wallet...\n");
nStart = GetTimeMillis();
bool fFirstRun;
pwalletMain = new CWallet("wallet.dat");
pwalletMain = new CWallet(GetArg("-wallet", "wallet.dat"));
int nLoadWalletRet = pwalletMain->LoadWallet(fFirstRun);
if (nLoadWalletRet != DB_LOAD_OK)
{
@@ -406,7 +407,7 @@ bool AppInit2(int argc, char* argv[])
pindexRescan = pindexGenesisBlock;
else
{
CWalletDB walletdb("wallet.dat");
CWalletDB walletdb(GetArg("-wallet", "wallet.dat"));
CBlockLocator locator;
if (walletdb.ReadBestBlock(locator))
pindexRescan = locator.GetBlockIndex();
3 changes: 2 additions & 1 deletion src/uibase.cpp
Original file line number Diff line number Diff line change
@@ -6,6 +6,7 @@
///////////////////////////////////////////////////////////////////////////

#include "uibase.h"
#include "util.h"

#include "xpm/about.xpm"
#include "xpm/addressbook20.xpm"
@@ -96,7 +97,7 @@ CMainFrameBase::CMainFrameBase( wxWindow* parent, wxWindowID id, const wxString&
wxBoxSizer* bSizer66;
bSizer66 = new wxBoxSizer( wxHORIZONTAL );

m_staticText41 = new wxStaticText( this, wxID_ANY, _("Balance:"), wxDefaultPosition, wxSize( -1,15 ), 0 );
m_staticText41 = new wxStaticText( this, wxID_ANY, _("Balance in "+GetArg("-wallet", "wallet.dat")+":"), wxDefaultPosition, wxSize( -1,15 ), 0 );
m_staticText41->Wrap( -1 );
bSizer66->Add( m_staticText41, 0, wxALIGN_CENTER_VERTICAL|wxTOP|wxBOTTOM|wxLEFT, 5 );