This commit is contained in:
Sasha Szpakowski
2024-10-17 23:10:10 -03:00
parent 8c52dce565
commit 7ca40027e0
224 changed files with 8872 additions and 6448 deletions
+2 -2
View File
@@ -20,7 +20,7 @@
*/
#include "SDL_internal.h"
#if defined(SDL_PLATFORM_UNIX) || defined(SDL_PLATFORM_APPLE)
#if defined(HAVE_GETHOSTNAME) && !defined(SDL_PLATFORM_WINDOWS)
#include <unistd.h>
#endif
@@ -299,7 +299,7 @@ int SDL_URIToLocal(const char *src, char *dst)
const size_t src_len = hostname_end - (src + 1);
size_t hostname_len;
#if defined(SDL_PLATFORM_UNIX) || defined(SDL_PLATFORM_APPLE)
#if defined(HAVE_GETHOSTNAME) && !defined(SDL_PLATFORM_WINDOWS)
char hostname[257];
if (gethostname(hostname, 255) == 0) {
hostname[256] = '\0';