mirror of
https://github.com/Xahau/xahaud.git
synced 2025-12-06 17:27:52 +00:00
more todo cleanup
This commit is contained in:
@@ -647,8 +647,6 @@ unserialize_keylet(uint8_t* ptr, uint32_t len)
|
||||
}
|
||||
|
||||
|
||||
// RH TODO: this is used by sethook to determine the value stored in ltHOOK
|
||||
// replace this with votable value
|
||||
uint32_t hook::maxHookStateDataSize(void) {
|
||||
return 256U;
|
||||
}
|
||||
@@ -2877,6 +2875,7 @@ DEFINE_HOOK_FUNCTION(
|
||||
|
||||
// check the emitted txn is valid
|
||||
/* Emitted TXN rules
|
||||
* 0. Account must match the hook account
|
||||
* 1. Sequence: 0
|
||||
* 2. PubSigningKey: 000000000000000
|
||||
* 3. sfEmitDetails present and valid
|
||||
@@ -2887,6 +2886,13 @@ DEFINE_HOOK_FUNCTION(
|
||||
* 8. The generation cannot be higher than 10
|
||||
*/
|
||||
|
||||
// rule 0: account must match the hook account
|
||||
if (!stpTrans->isFieldPresent(sfAccount) || stpTrans->getAccountID(sfAccount) != hookCtx.result.account)
|
||||
{
|
||||
JLOG(j.trace())
|
||||
<< "HookEmit[" << HC_ACC() << "]: sfAccount does not match hook account";
|
||||
return EMISSION_FAILURE;
|
||||
}
|
||||
|
||||
// rule 1: sfSequence must be present and 0
|
||||
if (!stpTrans->isFieldPresent(sfSequence) || stpTrans->getFieldU32(sfSequence) != 0)
|
||||
|
||||
@@ -1546,8 +1546,8 @@ PeerImp::handleTransaction(
|
||||
if (stx->isFieldPresent(sfEmitDetails))
|
||||
{
|
||||
JLOG(p_journal_.warn()) << "Ignoring Network relayed Tx containing sfEmitDetails (handleTransaction).";
|
||||
//fee_ = Resource::feeHighBurdenPeer; // RH TODO: enable when relay bug is fixed
|
||||
//return;
|
||||
//fee_ = Resource::feeHighBurdenPeer; // RH TODO: fix
|
||||
return;
|
||||
}
|
||||
|
||||
int flags;
|
||||
|
||||
@@ -74,7 +74,7 @@ LedgerHandler::check()
|
||||
// Until some sane way to get full ledgers has been implemented,
|
||||
// disallow retrieving all state nodes.
|
||||
|
||||
uint32_t nodeNID = ctx.app.config().NETWORK_ID;
|
||||
uint32_t nodeNID = context_.app.config().NETWORK_ID;
|
||||
if (nodeNID == 21337)
|
||||
{
|
||||
// RH NOTE: production network requires rpc permission to dump full ledger
|
||||
|
||||
Reference in New Issue
Block a user