diff options
Diffstat (limited to 'src')
| -rw-r--r-- | src/lib/libcrypto/bio/b_print.c | 9 | 
1 files changed, 3 insertions, 6 deletions
diff --git a/src/lib/libcrypto/bio/b_print.c b/src/lib/libcrypto/bio/b_print.c index 09747767dd..c9d54809a7 100644 --- a/src/lib/libcrypto/bio/b_print.c +++ b/src/lib/libcrypto/bio/b_print.c  | |||
| @@ -1,4 +1,4 @@ | |||
| 1 | /* $OpenBSD: b_print.c,v 1.25 2014/06/12 15:49:28 deraadt Exp $ */ | 1 | /* $OpenBSD: b_print.c,v 1.26 2019/06/28 05:47:57 deraadt Exp $ */ | 
| 2 | 2 | ||
| 3 | /* Theo de Raadt places this file in the public domain. */ | 3 | /* Theo de Raadt places this file in the public domain. */ | 
| 4 | 4 | ||
| @@ -49,13 +49,10 @@ BIO_vprintf(BIO *bio, const char *format, va_list args) | |||
| 49 | char *buf = NULL; | 49 | char *buf = NULL; | 
| 50 | 50 | ||
| 51 | ret = vasprintf(&buf, format, args); | 51 | ret = vasprintf(&buf, format, args); | 
| 52 | if (buf == NULL) { | 52 | if (ret == -1) | 
| 53 | ret = -1; | 53 | return (ret); | 
| 54 | goto fail; | ||
| 55 | } | ||
| 56 | BIO_write(bio, buf, ret); | 54 | BIO_write(bio, buf, ret); | 
| 57 | free(buf); | 55 | free(buf); | 
| 58 | fail: | ||
| 59 | return (ret); | 56 | return (ret); | 
| 60 | } | 57 | } | 
| 61 | 58 | ||
