Fix snprintf missing for windows build
authorShane Lontis <shane.lontis@oracle.com>
Wed, 29 Apr 2020 06:19:16 +0000 (16:19 +1000)
committerShane Lontis <shane.lontis@oracle.com>
Thu, 30 Apr 2020 08:04:05 +0000 (18:04 +1000)
Reviewed-by: Richard Levitte <levitte@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/11675)

crypto/x509/v3_alt.c

index 52e936a..98ff0bc 100644 (file)
@@ -11,6 +11,7 @@
 #include "internal/cryptlib.h"
 #include <openssl/conf.h>
 #include <openssl/x509v3.h>
+#include <openssl/bio.h>
 #include "ext_dat.h"
 
 DEFINE_STACK_OF(CONF_VALUE)
@@ -126,7 +127,8 @@ STACK_OF(CONF_VALUE) *i2v_GENERAL_NAME(X509V3_EXT_METHOD *method,
             break;
         default:
             if (OBJ_obj2txt(oline, sizeof(oline), gen->d.otherName->type_id, 0) > 0) 
-                snprintf(othername, sizeof(othername), "othername: %s:", oline);
+                BIO_snprintf(othername, sizeof(othername), "othername: %s:",
+                             oline);
             else
                 strncpy(othername, "othername:", sizeof(othername));