Bugfix/win32 build warnings (#936)

* Changed win32 port of localtime to use secure OS API functions when compiled with MSVC

* Changed all the sprintf to use snprintf instead in BSC tests to ensure null string endings.
This commit is contained in:
Steve Karg
2025-03-03 10:32:28 -06:00
committed by GitHub
parent b0a26cf2cd
commit 7e725ce028
21 changed files with 317 additions and 275 deletions
+3 -1
View File
@@ -2770,7 +2770,9 @@ static void test_ADDRESS_RESOLUTION_ACK(void)
const char *err_desc = NULL;
web_socket_uris[0] = 0;
sprintf(web_socket_uris, "%s %s", "web_socket_uri1", "web_socket_uri2");
snprintf(
web_socket_uris, sizeof(web_socket_uris), "%s %s", "web_socket_uri1",
"web_socket_uri2");
memset(&origin.address, 0x91, BVLC_SC_VMAC_SIZE);
memset(&dest.address, 0xef, BVLC_SC_VMAC_SIZE);