Some trivial cleanups/fixes:

* Avoid throwing in OrderBookDB::processTxn
* Fix missing space in debug output
* Avoid duplicate lock of PathRequest in updateAll
* Avoid shadowing in insertPathRequest
* Improve indentation in runOnCoroutine
* Remove extraneous space in ServerHandlerImp::processRequest
This commit is contained in:
JoelKatz
2015-10-02 11:53:35 -07:00
committed by Vinnie Falco
parent 5b6cc3b036
commit 333ba69d60
5 changed files with 11 additions and 9 deletions

View File

@@ -113,8 +113,6 @@ void PathRequests::updateAll (std::shared_ptr <ReadView const> const& inLedger,
if (remove)
{
PathRequest::pointer pRequest = wRequest.lock ();
ScopedLockType sl (mLock);
// Remove any dangling weak pointers or weak pointers that refer to this path request.
@@ -179,8 +177,8 @@ void PathRequests::insertPathRequest (PathRequest::pointer const& req)
std::vector<PathRequest::wptr>::iterator it = mRequests.begin ();
while (it != mRequests.end ())
{
PathRequest::pointer req = it->lock ();
if (req && !req->isNew ())
PathRequest::pointer r = it->lock ();
if (r && !r->isNew ())
break; // This request has been handled, we come before it
// This is a newer request, we come after it