diff options
Diffstat (limited to 'src/lib/libssl/t1_enc.c')
-rw-r--r-- | src/lib/libssl/t1_enc.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/src/lib/libssl/t1_enc.c b/src/lib/libssl/t1_enc.c index 279e45db5d..0d34357eb4 100644 --- a/src/lib/libssl/t1_enc.c +++ b/src/lib/libssl/t1_enc.c | |||
@@ -178,7 +178,7 @@ int tls1_change_cipher_state(SSL *s, int which) | |||
178 | { | 178 | { |
179 | if ((s->enc_read_ctx == NULL) && | 179 | if ((s->enc_read_ctx == NULL) && |
180 | ((s->enc_read_ctx=(EVP_CIPHER_CTX *) | 180 | ((s->enc_read_ctx=(EVP_CIPHER_CTX *) |
181 | Malloc(sizeof(EVP_CIPHER_CTX))) == NULL)) | 181 | OPENSSL_malloc(sizeof(EVP_CIPHER_CTX))) == NULL)) |
182 | goto err; | 182 | goto err; |
183 | dd= s->enc_read_ctx; | 183 | dd= s->enc_read_ctx; |
184 | s->read_hash=m; | 184 | s->read_hash=m; |
@@ -197,7 +197,7 @@ int tls1_change_cipher_state(SSL *s, int which) | |||
197 | } | 197 | } |
198 | if (s->s3->rrec.comp == NULL) | 198 | if (s->s3->rrec.comp == NULL) |
199 | s->s3->rrec.comp=(unsigned char *) | 199 | s->s3->rrec.comp=(unsigned char *) |
200 | Malloc(SSL3_RT_MAX_ENCRYPTED_LENGTH); | 200 | OPENSSL_malloc(SSL3_RT_MAX_ENCRYPTED_LENGTH); |
201 | if (s->s3->rrec.comp == NULL) | 201 | if (s->s3->rrec.comp == NULL) |
202 | goto err; | 202 | goto err; |
203 | } | 203 | } |
@@ -208,7 +208,7 @@ int tls1_change_cipher_state(SSL *s, int which) | |||
208 | { | 208 | { |
209 | if ((s->enc_write_ctx == NULL) && | 209 | if ((s->enc_write_ctx == NULL) && |
210 | ((s->enc_write_ctx=(EVP_CIPHER_CTX *) | 210 | ((s->enc_write_ctx=(EVP_CIPHER_CTX *) |
211 | Malloc(sizeof(EVP_CIPHER_CTX))) == NULL)) | 211 | OPENSSL_malloc(sizeof(EVP_CIPHER_CTX))) == NULL)) |
212 | goto err; | 212 | goto err; |
213 | dd= s->enc_write_ctx; | 213 | dd= s->enc_write_ctx; |
214 | s->write_hash=m; | 214 | s->write_hash=m; |
@@ -355,9 +355,9 @@ int tls1_setup_key_block(SSL *s) | |||
355 | 355 | ||
356 | ssl3_cleanup_key_block(s); | 356 | ssl3_cleanup_key_block(s); |
357 | 357 | ||
358 | if ((p1=(unsigned char *)Malloc(num)) == NULL) | 358 | if ((p1=(unsigned char *)OPENSSL_malloc(num)) == NULL) |
359 | goto err; | 359 | goto err; |
360 | if ((p2=(unsigned char *)Malloc(num)) == NULL) | 360 | if ((p2=(unsigned char *)OPENSSL_malloc(num)) == NULL) |
361 | goto err; | 361 | goto err; |
362 | 362 | ||
363 | s->s3->tmp.key_block_length=num; | 363 | s->s3->tmp.key_block_length=num; |
@@ -374,7 +374,7 @@ printf("pre-master\n"); | |||
374 | #endif | 374 | #endif |
375 | tls1_generate_key_block(s,p1,p2,num); | 375 | tls1_generate_key_block(s,p1,p2,num); |
376 | memset(p2,0,num); | 376 | memset(p2,0,num); |
377 | Free(p2); | 377 | OPENSSL_free(p2); |
378 | #ifdef TLS_DEBUG | 378 | #ifdef TLS_DEBUG |
379 | printf("\nkey block\n"); | 379 | printf("\nkey block\n"); |
380 | { int z; for (z=0; z<num; z++) printf("%02X%c",p1[z],((z+1)%16)?' ':'\n'); } | 380 | { int z; for (z=0; z<num; z++) printf("%02X%c",p1[z],((z+1)%16)?' ':'\n'); } |