Fix crash

[extended tests]

Reviewed-by: Richard Levitte <levitte@openssl.org>
Reviewed-by: Tim Hudson <tjh@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/3700)
This commit is contained in:
Rich Salz 2017-06-15 18:51:10 -04:00
parent f48ad5cbdf
commit e2dba64c84

View file

@ -757,6 +757,8 @@ void ERR_add_error_vdata(int num, va_list args)
n = 0; n = 0;
for (i = 0; i < num; i++) { for (i = 0; i < num; i++) {
a = va_arg(args, char *); a = va_arg(args, char *);
if (a == NULL)
a = "<NULL>";
n += strlen(a); n += strlen(a);
if (n > s) { if (n > s) {
s = n + 20; s = n + 20;