From 828c2e3c7166ab917ce7002e884b602c4087796b Mon Sep 17 00:00:00 2001 From: sublimator Date: Wed, 25 Jun 2014 20:16:38 +0000 Subject: [PATCH] Restore checkpointed ledger under all paths in PathFind. --- src/ripple_app/paths/RippleCalc.cpp | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/ripple_app/paths/RippleCalc.cpp b/src/ripple_app/paths/RippleCalc.cpp index 24c17e9e7..6967c65aa 100644 --- a/src/ripple_app/paths/RippleCalc.cpp +++ b/src/ripple_app/paths/RippleCalc.cpp @@ -2819,6 +2819,13 @@ TER RippleCalc::rippleCalc ( } else { + // We must restore the activeLedger from lesCheckpoint in the case + // when iBest is -1 and just before the result is set to tesSUCCESS. + // There was an issue when not on the first increment and there was + // no best path, where we did not restore the ledger to the last + // checkpoint. + + activeLedger = lesCheckpoint.duplicate (); terResult = tesSUCCESS; } }