(file_path.c) Use strlcpy for these instead of snprintf

This commit is contained in:
twinaphex 2021-03-24 17:26:34 +01:00
parent ed0c9ef1dc
commit 5aaf4150e2
1 changed files with 2 additions and 2 deletions

View File

@ -509,7 +509,7 @@ void path_basedir(char *path)
if (last) if (last)
last[1] = '\0'; last[1] = '\0';
else else
snprintf(path, 3, "." PATH_DEFAULT_SLASH()); strlcpy(path, "." PATH_DEFAULT_SLASH(), 3);
} }
/** /**
@ -1189,7 +1189,7 @@ void path_basedir_wrapper(char *path)
if (last) if (last)
last[1] = '\0'; last[1] = '\0';
else else
snprintf(path, 3, "." PATH_DEFAULT_SLASH()); strlcpy(path, "." PATH_DEFAULT_SLASH(), 3);
} }
#if !defined(RARCH_CONSOLE) && defined(RARCH_INTERNAL) #if !defined(RARCH_CONSOLE) && defined(RARCH_INTERNAL)