Disable transaction saving for now

This commit is contained in:
Arthur Britto
2012-05-16 00:36:00 -07:00
parent bca7dcad74
commit 0ca48989d8
2 changed files with 10 additions and 1 deletions

View File

@@ -212,6 +212,9 @@ void Transaction::saveTransaction(Transaction::pointer txn)
bool Transaction::save() const bool Transaction::save() const
{ // This code needs to be fixed to support new-style transactions - FIXME { // This code needs to be fixed to support new-style transactions - FIXME
#if 0
// Identify minimums fields to write for now.
// Also maybe write effected accounts for use later.
if ((mStatus == INVALID) || (mStatus == REMOVED)) return false; if ((mStatus == INVALID) || (mStatus == REMOVED)) return false;
std::string sql = "INSERT INTO Transactions " std::string sql = "INSERT INTO Transactions "
@@ -251,6 +254,8 @@ bool Transaction::save() const
ScopedLock sl(theApp->getTxnDB()->getDBLock()); ScopedLock sl(theApp->getTxnDB()->getDBLock());
Database* db = theApp->getTxnDB()->getDB(); Database* db = theApp->getTxnDB()->getDB();
return db->executeSQL(sql); return db->executeSQL(sql);
#endif
return true;
} }
Transaction::pointer Transaction::transactionFromSQL(const std::string& sql) Transaction::pointer Transaction::transactionFromSQL(const std::string& sql)

View File

@@ -255,7 +255,7 @@ TransactionEngineResult TransactionEngine::doClaim(const SerializedTransaction&
} }
// //
// Verify claim is authorized // Verify claim is authorized for public key.
// //
std::vector<unsigned char> vucCipher = txn.getITFieldVL(sfGenerator); std::vector<unsigned char> vucCipher = txn.getITFieldVL(sfGenerator);
@@ -272,6 +272,10 @@ TransactionEngineResult TransactionEngine::doClaim(const SerializedTransaction&
return tenINVALID; return tenINVALID;
} }
//
// Verify generator not already in use.
//
uint160 hGeneratorID = naAccountPublic.getAccountID(); uint160 hGeneratorID = naAccountPublic.getAccountID();
qry = lepNONE; qry = lepNONE;