C++ compat
This commit is contained in:
parent
d3e716aa49
commit
4f70e7c171
@ -21,9 +21,9 @@ int main(void)
|
|||||||
unsigned char *alicepk;
|
unsigned char *alicepk;
|
||||||
int i;
|
int i;
|
||||||
|
|
||||||
k = sodium_malloc(crypto_scalarmult_BYTES);
|
k = (unsigned char *) sodium_malloc(crypto_scalarmult_BYTES);
|
||||||
bobsk = sodium_malloc(crypto_scalarmult_SCALARBYTES);
|
bobsk = (unsigned char *) sodium_malloc(crypto_scalarmult_SCALARBYTES);
|
||||||
alicepk = sodium_malloc(crypto_scalarmult_SCALARBYTES);
|
alicepk = (unsigned char *) sodium_malloc(crypto_scalarmult_SCALARBYTES);
|
||||||
assert(k != NULL && bobsk != NULL && alicepk != NULL);
|
assert(k != NULL && bobsk != NULL && alicepk != NULL);
|
||||||
|
|
||||||
memcpy(bobsk, bobsk_, crypto_scalarmult_SCALARBYTES);
|
memcpy(bobsk, bobsk_, crypto_scalarmult_SCALARBYTES);
|
||||||
|
Loading…
Reference in New Issue
Block a user