http_test.c: Replace snprintf by BIO_snprintf

Reviewed-by: Matt Caswell <matt@openssl.org>
Reviewed-by: Viktor Dukhovni <viktor@openssl.org>
Reviewed-by: Paul Dale <ppzgs1@gmail.com>
(Merged from https://github.com/openssl/openssl/pull/26925)
This commit is contained in:
Jean-Frederic Clere 2025-02-27 17:35:05 +01:00 committed by Tomas Mraz
parent 2411f9b662
commit 7e431da4d8

View File

@ -159,8 +159,8 @@ static int test_http_method(int do_get, int do_txt, int suggested_status)
int res = 0;
int real_server = do_txt && 0; /* remove "&& 0" for using real server */
snprintf(path, sizeof(path), "/%d%s", suggested_status,
do_get > 1 ? "/will-be-redirected" : RPATH);
BIO_snprintf(path, sizeof(path), "/%d%s", suggested_status,
do_get > 1 ? "/will-be-redirected" : RPATH);
if (do_txt) {
content_type = "text/plain";
req = BIO_new(BIO_s_mem());