From 7f82b95dbdcfb2876756c73bbdfe53cb13343b8e Mon Sep 17 00:00:00 2001 From: JoelKatz Date: Mon, 15 Apr 2013 05:44:35 -0700 Subject: [PATCH] Don't send a zero amount. --- src/cpp/ripple/Pathfinder.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/cpp/ripple/Pathfinder.cpp b/src/cpp/ripple/Pathfinder.cpp index 0ffaba680..07550972e 100644 --- a/src/cpp/ripple/Pathfinder.cpp +++ b/src/cpp/ripple/Pathfinder.cpp @@ -150,8 +150,8 @@ Pathfinder::Pathfinder(Ledger::ref ledger, mLedger(ledger) { - if ((mSrcAccountID == mDstAccountID) && (mSrcCurrencyID == mDstAmount.getCurrency())) - { // no need to send to same account with same currency + if (((mSrcAccountID == mDstAccountID) && (mSrcCurrencyID == mDstAmount.getCurrency())) || mDstAmount.isZero()) + { // no need to send to same account with same currency, must send non-zero bValid = false; return; }