diff options
author | Nils Larsch <nils@openssl.org> | 2006-01-29 23:12:22 +0000 |
---|---|---|
committer | Nils Larsch <nils@openssl.org> | 2006-01-29 23:12:22 +0000 |
commit | 8c5a2bd6bb9a8c2bb3e1b63c03e57bb1115275d1 (patch) | |
tree | 6f47255125d6970ab07881a58be1e7df1e4e9490 /ssl/d1_enc.c | |
parent | 25a58453ff5b73e7b4d5e2764d7924424694a82a (diff) |
add additional checks + cleanup
Submitted by: David Hartman <david_hartman@symantec.com>
Diffstat (limited to 'ssl/d1_enc.c')
-rw-r--r-- | ssl/d1_enc.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/ssl/d1_enc.c b/ssl/d1_enc.c index 42997eaee9..cbff7495c5 100644 --- a/ssl/d1_enc.c +++ b/ssl/d1_enc.c @@ -146,7 +146,10 @@ int dtls1_enc(SSL *s, int send) fprintf(stderr, "%s:%d: rec->data != rec->input\n", __FILE__, __LINE__); else if ( EVP_CIPHER_block_size(ds->cipher) > 1) - RAND_bytes(rec->input, EVP_CIPHER_block_size(ds->cipher)); + { + if (!RAND_bytes(rec->input, EVP_CIPHER_block_size(ds->cipher))) + return -1; + } } } else |