Minor fix to keysSet atomic_bool

This commit is contained in:
Stephen Seo 2020-01-05 16:05:17 +09:00
parent e644cd86b1
commit e66e6c7b74

View file

@ -2307,6 +2307,7 @@ int UDPC_set_libsodium_keys(UDPC_HContext ctx, unsigned char *sk, unsigned char
return 0;
}
c->keysSet.store(false);
std::memcpy(c->sk, sk, crypto_sign_SECRETKEYBYTES);
std::memcpy(c->pk, pk, crypto_sign_PUBLICKEYBYTES);
c->keysSet.store(true);