Merge master (0.60.2) into develop (0.70.0-b2)

This commit is contained in:
Nik Bougalis
2017-03-31 11:53:49 -07:00
6 changed files with 60 additions and 37 deletions

View File

@@ -595,6 +595,7 @@ TER DirectStepI::check (StrandContext const& ctx) const
return temBAD_PATH;
}
auto sleLine = ctx.view.read (keylet::line (src_, dst_, currency_));
{
auto sleSrc = ctx.view.read (keylet::account (src_));
if (!sleSrc)
@@ -605,8 +606,6 @@ TER DirectStepI::check (StrandContext const& ctx) const
return terNO_ACCOUNT;
}
auto sleLine = ctx.view.read (keylet::line (src_, dst_, currency_));
if (!sleLine)
{
JLOG (j_.trace()) << "DirectStepI: No credit line. " << *this;
@@ -643,6 +642,18 @@ TER DirectStepI::check (StrandContext const& ctx) const
if (ter != tesSUCCESS)
return ter;
}
if (fix1449(ctx.view.info().parentCloseTime))
{
if (ctx.prevStep->bookStepBook())
{
auto const noRippleSrcToDst =
((*sleLine)[sfFlags] &
((src_ > dst_) ? lsfHighNoRipple : lsfLowNoRipple));
if (noRippleSrcToDst)
return terNO_RIPPLE;
}
}
}
{