projects
/
openssl.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
4fd2ead
)
RAND_bytes's return values is 0 for an error, not -1.
author
Bodo Möller
<bodo@openssl.org>
Sat, 15 Jan 2000 20:24:12 +0000
(20:24 +0000)
committer
Bodo Möller
<bodo@openssl.org>
Sat, 15 Jan 2000 20:24:12 +0000
(20:24 +0000)
crypto/evp/p_seal.c
patch
|
blob
|
history
diff --git
a/crypto/evp/p_seal.c
b/crypto/evp/p_seal.c
index 7966545e21db6ce1d1b518abd68962918bce7360..e372f138c70d508f0cb18bb68e0ebd5a95dce38c 100644
(file)
--- a/
crypto/evp/p_seal.c
+++ b/
crypto/evp/p_seal.c
@@
-73,7
+73,7
@@
int EVP_SealInit(EVP_CIPHER_CTX *ctx, EVP_CIPHER *type, unsigned char **ek,
int i;
if (npubk <= 0) return(0);
- if (RAND_bytes(key,EVP_MAX_KEY_LENGTH)
== -1
) return(0);
+ if (RAND_bytes(key,EVP_MAX_KEY_LENGTH)
<= 0
) return(0);
if (type->iv_len > 0)
RAND_bytes(iv,type->iv_len);