From 47d70e1ae67649f788d6fe7201d683c45e574436 Mon Sep 17 00:00:00 2001 From: Steel Titanium Date: Sun, 12 Apr 2020 17:56:12 -0400 Subject: [PATCH] Fix cmake using wrong libs if internal libs is turned on Use '\0' instead, just in case --- src/CMakeLists.txt | 4 ++-- src/d_clisrv.c | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index 19b0e07c6..4b89a79ed 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -398,9 +398,9 @@ if(${SRB2_CONFIG_HAVE_CURL}) set(CURL_FOUND ON) set(CURL_INCLUDE_DIRS ${CMAKE_SOURCE_DIR}/libs/curl) if(${SRB2_SYSTEM_BITS} EQUAL 64) - set(CURL_LIBRARIES "-L${CMAKE_SOURCE_DIR}/libs/curl/lib32 -lcurl") - else() # 32-bit set(CURL_LIBRARIES "-L${CMAKE_SOURCE_DIR}/libs/curl/lib64 -lcurl") + else() # 32-bit + set(CURL_LIBRARIES "-L${CMAKE_SOURCE_DIR}/libs/curl/lib32 -lcurl") endif() else() find_package(CURL) diff --git a/src/d_clisrv.c b/src/d_clisrv.c index f25bcf7b8..817fb93a0 100644 --- a/src/d_clisrv.c +++ b/src/d_clisrv.c @@ -1449,7 +1449,7 @@ static void SV_SendServerInfo(INT32 node, tic_t servertime) // If there's an encoding error, send nothing, we accept that the above may be truncated strncpy(netbuffer->u.serverinfo.httpsource, "", mirror_length); - netbuffer->u.serverinfo.httpsource[MAX_MIRROR_LENGTH-1] = 0; + netbuffer->u.serverinfo.httpsource[MAX_MIRROR_LENGTH-1] = '\0'; #endif p = PutFileNeeded(0);