mirror of
https://github.com/Xahau/xahaud.git
synced 2025-12-06 17:27:52 +00:00
Reject a non-positive destination amount immediately.
This commit is contained in:
@@ -1418,6 +1418,7 @@ Json::Value RPCHandler::doRipplePathFind (Json::Value params, LoadType* loadType
|
||||
// Parse saDstAmount.
|
||||
!params.isMember ("destination_amount")
|
||||
|| !saDstAmount.bSetJson (params["destination_amount"])
|
||||
|| !saDstAmount.isPositive()
|
||||
|| (!!saDstAmount.getCurrency () && (!saDstAmount.getIssuer () || ACCOUNT_ONE == saDstAmount.getIssuer ())))
|
||||
{
|
||||
WriteLog (lsINFO, RPCHandler) << "Bad destination_amount.";
|
||||
|
||||
Reference in New Issue
Block a user