Remove unused ctor arguments

This commit is contained in:
Vinnie Falco
2013-06-27 07:57:14 -07:00
parent cb900169d1
commit 662119dd55
5 changed files with 18 additions and 15 deletions

View File

@@ -4,11 +4,10 @@
*/
//==============================================================================
Database::Database (const char* host, const char* user, const char* pass) : mNumCol (0)
Database::Database (const char* host)
: mNumCol (0)
{
mDBPass = pass;
mHost = host;
mUser = user;
}
Database::~Database ()

View File

@@ -26,9 +26,7 @@ class JobQueue;
class Database
{
public:
// VFALCO TODO how are user and password even used?
//
Database (const char* host, const char* user, const char* pass);
explicit Database (const char* host);
virtual ~Database ();
@@ -36,11 +34,6 @@ public:
virtual void disconnect () = 0;
std::string& getPass ()
{
return (mDBPass);
}
// returns true if the query went ok
virtual bool executeSQL (const char* sql, bool fail_okay = false) = 0;
@@ -105,9 +98,7 @@ protected:
bool getColNumber (const char* colName, int* retIndex);
int mNumCol;
std::string mUser;
std::string mHost;
std::string mDBPass;
std::vector <std::string> mColNameTable;
};

View File

@@ -75,6 +75,16 @@ bool InboundLedgers::awaitLedgerData (uint256 const& ledgerHash)
return true;
}
/*
This gets called when
"We got some data from an inbound ledger"
inboundLedgerTrigger:
"What do we do with this partial data?"
Figures out what to do with the responses to our requests for information.
*/
// means "We got some data from an inbound ledger"
void InboundLedgers::gotLedgerData (Job&, uint256 hash,
boost::shared_ptr<protocol::TMLedgerData> packet_ptr, boost::weak_ptr<Peer> wPeer)
{

View File

@@ -35,7 +35,10 @@ SqliteStatement::~SqliteStatement ()
sqlite3_finalize (statement);
}
SqliteDatabase::SqliteDatabase (const char* host) : Database (host, "", ""), mWalQ (NULL), walRunning (false)
SqliteDatabase::SqliteDatabase (const char* host)
: Database (host)
, mWalQ (NULL)
, walRunning (false)
{
mConnection = NULL;
mAuxConnection = NULL;