From 6554c681c8bcd707fa97a91e6fd93748f617cb42 Mon Sep 17 00:00:00 2001 From: Leonard Lyubich Date: Tue, 19 Apr 2022 11:18:29 +0300 Subject: [PATCH] [#190] crypto: Doc RegisterScheme isn't thread-unsafe Signed-off-by: Leonard Lyubich --- crypto/signer.go | 2 ++ 1 file changed, 2 insertions(+) diff --git a/crypto/signer.go b/crypto/signer.go index ccd8a07..7ca2fac 100644 --- a/crypto/signer.go +++ b/crypto/signer.go @@ -32,6 +32,8 @@ var publicKeys = make(map[Scheme]func() PublicKey) // function in packages that implement signature schemes. // // RegisterScheme panics if function for the given Scheme is already registered. +// +// Note that RegisterScheme isn't tread-safe. func RegisterScheme(scheme Scheme, f func() PublicKey) { _, ok := publicKeys[scheme] if ok {