From a8578c73f8cd8cb5c43b974ac67042699e08339c Mon Sep 17 00:00:00 2001 From: Nik Bougalis Date: Mon, 24 Nov 2014 20:29:36 -0800 Subject: [PATCH] Remove support for deprecated PreviousTxnID field (RIPD-710): The PreviousTxnID field has been deprecated and should not be used for transactions that use the field will now be rejected. The AccountTxnID feature should be used instead by enabling transaction tracking and specifying a transaction ID at submission. More details are available at: https://ripple.com/build/transactions/#accounttxnid --- src/ripple/app/transactors/Transactor.cpp | 7 +------ src/ripple/protocol/impl/TxFormats.cpp | 1 - 2 files changed, 1 insertion(+), 7 deletions(-) diff --git a/src/ripple/app/transactors/Transactor.cpp b/src/ripple/app/transactors/Transactor.cpp index 17cb2557e4..fe54f250d2 100644 --- a/src/ripple/app/transactors/Transactor.cpp +++ b/src/ripple/app/transactors/Transactor.cpp @@ -204,11 +204,6 @@ TER Transactor::checkSeq () return tefPAST_SEQ; } - // Deprecated: Do not use - if (mTxn.isFieldPresent (sfPreviousTxnID) && - (mTxnAccount->getFieldH256 (sfPreviousTxnID) != mTxn.getFieldH256 (sfPreviousTxnID))) - return tefWRONG_PRIOR; - if (mTxn.isFieldPresent (sfAccountTxnID) && (mTxnAccount->getFieldH256 (sfAccountTxnID) != mTxn.getFieldH256 (sfAccountTxnID))) return tefWRONG_PRIOR; @@ -228,7 +223,7 @@ TER Transactor::checkSeq () // check stuff before you bother to lock the ledger TER Transactor::preCheck () { - mTxnAccountID = mTxn.getSourceAccount ().getAccountID (); + mTxnAccountID = mTxn.getSourceAccount ().getAccountID (); if (!mTxnAccountID) { diff --git a/src/ripple/protocol/impl/TxFormats.cpp b/src/ripple/protocol/impl/TxFormats.cpp index 56cfe50b74..ff6157f32c 100644 --- a/src/ripple/protocol/impl/TxFormats.cpp +++ b/src/ripple/protocol/impl/TxFormats.cpp @@ -94,7 +94,6 @@ void TxFormats::addCommonFields (Item& item) << SOElement(sfSourceTag, SOE_OPTIONAL) << SOElement(sfAccount, SOE_REQUIRED) << SOElement(sfSequence, SOE_REQUIRED) - << SOElement(sfPreviousTxnID, SOE_OPTIONAL) // Deprecated: Do not use << SOElement(sfLastLedgerSequence, SOE_OPTIONAL) << SOElement(sfAccountTxnID, SOE_OPTIONAL) << SOElement(sfFee, SOE_REQUIRED)