From d6061a5faa8ef864404a4bb3e7bab4195cd83a27 Mon Sep 17 00:00:00 2001 From: "Andres G. Aragoneses" Date: Fri, 5 Feb 2021 11:18:27 +0800 Subject: [PATCH] Key: reuse KEY_SIZE Similar commit as https://github.com/MetacoSA/NBitcoin/commit/ce7598f5c1bad8c49f8f71a7b5399a2fb01616bd --- NBitcoin/Key.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/NBitcoin/Key.cs b/NBitcoin/Key.cs index eec7049d4..c13d1bf41 100644 --- a/NBitcoin/Key.cs +++ b/NBitcoin/Key.cs @@ -155,7 +155,7 @@ public SchnorrSignature SignSchnorr(uint256 hash) { AssertNotDiposed(); #if HAS_SPAN - Span h = stackalloc byte[32]; + Span h = stackalloc byte[KEY_SIZE]; hash.ToBytes(h); return new SchnorrSignature(_ECKey.SignSchnorr(h)); #else