From c16475e7c11c6e1fcf81a062a825ee5e30089daa Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Vitor=20Naz=C3=A1rio=20Coelho?= Date: Mon, 7 Jan 2019 16:50:36 -0200 Subject: [PATCH] Updating Unknown to Policy Fail (#533) --- neo/Ledger/Blockchain.cs | 2 +- neo/Ledger/RelayResultReason.cs | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/neo/Ledger/Blockchain.cs b/neo/Ledger/Blockchain.cs index 94a7ec2274..db9ecb1cf5 100644 --- a/neo/Ledger/Blockchain.cs +++ b/neo/Ledger/Blockchain.cs @@ -388,7 +388,7 @@ private RelayResultReason OnNewTransaction(Transaction transaction) if (!transaction.Verify(currentSnapshot, GetMemoryPool())) return RelayResultReason.Invalid; if (!Plugin.CheckPolicy(transaction)) - return RelayResultReason.Unknown; + return RelayResultReason.PolicyFail; if (!mem_pool.TryAdd(transaction.Hash, transaction)) return RelayResultReason.OutOfMemory; diff --git a/neo/Ledger/RelayResultReason.cs b/neo/Ledger/RelayResultReason.cs index f66504846f..e698d0ea34 100644 --- a/neo/Ledger/RelayResultReason.cs +++ b/neo/Ledger/RelayResultReason.cs @@ -7,6 +7,7 @@ public enum RelayResultReason : byte OutOfMemory, UnableToVerify, Invalid, + PolicyFail, Unknown } }