mirror of
https://github.com/XRPLF/rippled.git
synced 2025-11-24 13:05:53 +00:00
Missing startIterRows.
This commit is contained in:
@@ -89,8 +89,8 @@ HashedObject::pointer HashedObject::retrieve(const uint256& hash)
|
|||||||
ScopedLock sl(theApp->getHashNodeDB()->getDBLock());
|
ScopedLock sl(theApp->getHashNodeDB()->getDBLock());
|
||||||
Database* db=theApp->getHashNodeDB()->getDB();
|
Database* db=theApp->getHashNodeDB()->getDB();
|
||||||
|
|
||||||
if(!db->executeSQL(sql.c_str())) return HashedObject::pointer();
|
if(!db->executeSQL(sql.c_str()) || !db->startIterRows() || !db->getNextRow())
|
||||||
if(!db->getNextRow()) return HashedObject::pointer();
|
return HashedObject::pointer();
|
||||||
|
|
||||||
std::string type;
|
std::string type;
|
||||||
db->getStr("ObjType", type);
|
db->getStr("ObjType", type);
|
||||||
|
|||||||
@@ -343,7 +343,7 @@ Ledger::pointer Ledger::getSQL(const std::string& sql)
|
|||||||
{
|
{
|
||||||
ScopedLock sl(theApp->getLedgerDB()->getDBLock());
|
ScopedLock sl(theApp->getLedgerDB()->getDBLock());
|
||||||
Database *db=theApp->getLedgerDB()->getDB();
|
Database *db=theApp->getLedgerDB()->getDB();
|
||||||
if(!db->executeSQL(sql.c_str()) || !db->getNextRow())
|
if(!db->executeSQL(sql.c_str()) || !db->startIterRows() || !db->getNextRow())
|
||||||
return Ledger::pointer();
|
return Ledger::pointer();
|
||||||
|
|
||||||
db->getStr("LedgerHash", hash);
|
db->getStr("LedgerHash", hash);
|
||||||
|
|||||||
@@ -23,8 +23,8 @@ CKey::pointer PubKeyCache::locate(const uint160& id)
|
|||||||
{ // is it in the database
|
{ // is it in the database
|
||||||
ScopedLock sl(theApp->getTxnDB()->getDBLock());
|
ScopedLock sl(theApp->getTxnDB()->getDBLock());
|
||||||
Database* db=theApp->getTxnDB()->getDB();
|
Database* db=theApp->getTxnDB()->getDB();
|
||||||
if(!db->executeSQL(sql.c_str())) return CKey::pointer();
|
if(!db->executeSQL(sql.c_str()) || !db->startIterRows() || !db->getNextRow())
|
||||||
if(!db->getNextRow()) return CKey::pointer();
|
return CKey::pointer();
|
||||||
pkSize=db->getBinary("PubKey", &(data.front()), data.size());
|
pkSize=db->getBinary("PubKey", &(data.front()), data.size());
|
||||||
db->endIterRows();
|
db->endIterRows();
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -175,8 +175,8 @@ Transaction::pointer Transaction::transactionFromSQL(const std::string& sql)
|
|||||||
ScopedLock sl(theApp->getTxnDB()->getDBLock());
|
ScopedLock sl(theApp->getTxnDB()->getDBLock());
|
||||||
Database* db=theApp->getTxnDB()->getDB();
|
Database* db=theApp->getTxnDB()->getDB();
|
||||||
|
|
||||||
if(!db->executeSQL(sql.c_str())) return Transaction::pointer();
|
if(!db->executeSQL(sql.c_str()) || !db->startIterRows() || !db->getNextRow())
|
||||||
if(!db->getNextRow()) return Transaction::pointer();
|
return Transaction::pointer();
|
||||||
|
|
||||||
db->getStr("TransID", transID);
|
db->getStr("TransID", transID);
|
||||||
db->getStr("FromID", fromID);
|
db->getStr("FromID", fromID);
|
||||||
|
|||||||
Reference in New Issue
Block a user