diff options
author | 2014-07-22 02:21:20 +0000 | |
---|---|---|
committer | 2014-07-22 02:21:20 +0000 | |
commit | 694428926dc83282ccb4d9e48dd9f22565103267 (patch) | |
tree | d6d7e4990a729c08f79b3319616873dcc91cacc4 /lib/libssl/src/crypto/ui/ui_lib.c | |
parent | Handle msgbuf_write() returning EAGAIN. (diff) | |
download | wireguard-openbsd-694428926dc83282ccb4d9e48dd9f22565103267.tar.xz wireguard-openbsd-694428926dc83282ccb4d9e48dd9f22565103267.zip |
Kill a bunch more BUF_strdup's - these are converted to have a check for
NULL before an intrinsic strdup.
ok miod@
Diffstat (limited to 'lib/libssl/src/crypto/ui/ui_lib.c')
-rw-r--r-- | lib/libssl/src/crypto/ui/ui_lib.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/libssl/src/crypto/ui/ui_lib.c b/lib/libssl/src/crypto/ui/ui_lib.c index 4fabcd99093..baf86d7635b 100644 --- a/lib/libssl/src/crypto/ui/ui_lib.c +++ b/lib/libssl/src/crypto/ui/ui_lib.c @@ -1,4 +1,4 @@ -/* $OpenBSD: ui_lib.c,v 1.27 2014/07/13 16:03:10 beck Exp $ */ +/* $OpenBSD: ui_lib.c,v 1.28 2014/07/22 02:21:20 beck Exp $ */ /* Written by Richard Levitte (richard@levitte.org) for the OpenSSL * project 2001. */ @@ -585,8 +585,8 @@ UI_create_method(char *name) { UI_METHOD *ui_method = calloc(1, sizeof(UI_METHOD)); - if (ui_method) - ui_method->name = BUF_strdup(name); + if (ui_method && name) + ui_method->name = strdup(name); return ui_method; } |