summaryrefslogtreecommitdiff
path: root/src/lib/libcrypto/engine/eng_dyn.c
diff options
context:
space:
mode:
authorbeck <>2014-07-13 16:03:10 +0000
committerbeck <>2014-07-13 16:03:10 +0000
commit6e4dfa23733fddf37830d1039cf31a2ffb86bdaf (patch)
treec2bbb8405534dcf838bc686b6748045284f3966b /src/lib/libcrypto/engine/eng_dyn.c
parent143b41eb184dd7da7b6f74162483016fbb5faab0 (diff)
downloadopenbsd-6e4dfa23733fddf37830d1039cf31a2ffb86bdaf.tar.gz
openbsd-6e4dfa23733fddf37830d1039cf31a2ffb86bdaf.tar.bz2
openbsd-6e4dfa23733fddf37830d1039cf31a2ffb86bdaf.zip
The bell tolls for BUF_strdup - Start the migration to using
intrinsics. This is the easy ones, a few left to check one at a time. ok miod@ deraadt@
Diffstat (limited to 'src/lib/libcrypto/engine/eng_dyn.c')
-rw-r--r--src/lib/libcrypto/engine/eng_dyn.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/lib/libcrypto/engine/eng_dyn.c b/src/lib/libcrypto/engine/eng_dyn.c
index ec2ad7a8e7..dfb35a8403 100644
--- a/src/lib/libcrypto/engine/eng_dyn.c
+++ b/src/lib/libcrypto/engine/eng_dyn.c
@@ -1,4 +1,4 @@
1/* $OpenBSD: eng_dyn.c,v 1.11 2014/07/10 13:58:22 jsing Exp $ */ 1/* $OpenBSD: eng_dyn.c,v 1.12 2014/07/13 16:03:09 beck Exp $ */
2/* Written by Geoff Thorpe (geoff@geoffthorpe.net) for the OpenSSL 2/* Written by Geoff Thorpe (geoff@geoffthorpe.net) for the OpenSSL
3 * project 2001. 3 * project 2001.
4 */ 4 */
@@ -348,7 +348,7 @@ dynamic_ctrl(ENGINE *e, int cmd, long i, void *p, void (*f)(void))
348 p = NULL; 348 p = NULL;
349 free((void *)ctx->DYNAMIC_LIBNAME); 349 free((void *)ctx->DYNAMIC_LIBNAME);
350 if (p) 350 if (p)
351 ctx->DYNAMIC_LIBNAME = BUF_strdup(p); 351 ctx->DYNAMIC_LIBNAME = strdup(p);
352 else 352 else
353 ctx->DYNAMIC_LIBNAME = NULL; 353 ctx->DYNAMIC_LIBNAME = NULL;
354 return (ctx->DYNAMIC_LIBNAME ? 1 : 0); 354 return (ctx->DYNAMIC_LIBNAME ? 1 : 0);
@@ -361,7 +361,7 @@ dynamic_ctrl(ENGINE *e, int cmd, long i, void *p, void (*f)(void))
361 p = NULL; 361 p = NULL;
362 free((void *)ctx->engine_id); 362 free((void *)ctx->engine_id);
363 if (p) 363 if (p)
364 ctx->engine_id = BUF_strdup(p); 364 ctx->engine_id = strdup(p);
365 else 365 else
366 ctx->engine_id = NULL; 366 ctx->engine_id = NULL;
367 return (ctx->engine_id ? 1 : 0); 367 return (ctx->engine_id ? 1 : 0);
@@ -391,7 +391,7 @@ dynamic_ctrl(ENGINE *e, int cmd, long i, void *p, void (*f)(void))
391 return 0; 391 return 0;
392 } 392 }
393 { 393 {
394 char *tmp_str = BUF_strdup(p); 394 char *tmp_str = strdup(p);
395 if (!tmp_str) { 395 if (!tmp_str) {
396 ENGINEerr(ENGINE_F_DYNAMIC_CTRL, 396 ENGINEerr(ENGINE_F_DYNAMIC_CTRL,
397 ERR_R_MALLOC_FAILURE); 397 ERR_R_MALLOC_FAILURE);