Merge branch '0.4.x' into 0.5.x

This commit is contained in:
Luke Dashjr 2012-11-29 03:35:35 +00:00
commit 72c8166589

View File

@ -1385,7 +1385,8 @@ Value backupwallet(const Array& params, bool fHelp)
"Safely copies wallet.dat to destination, which can be a directory or a path with filename.");
string strDest = params[0].get_str();
BackupWallet(*pwalletMain, strDest);
if (!BackupWallet(*pwalletMain, strDest))
throw JSONRPCError(RPC_WALLET_ERROR, "Error: Wallet backup failed!");
return Value::null;
}