libgimpconfig: Use strcat_s on Windows to fix CRT_INSECURE_DEPRECATE warns

This commit is contained in:
Bruno Lopes 2026-03-31 22:21:20 -03:00
parent f4969c2f80
commit fe95ec6ecf

View file

@ -632,7 +632,11 @@ gimp_config_path_expand_only (const gchar *path,
if (*p == '~' && home)
{
*n = '\0';
#ifndef _UCRT
strcat (n, home);
#else
strcat_s (n, (length + 1) - (n - expanded), home);
#endif
n += strlen (home);
p += 1;
}
@ -645,7 +649,11 @@ gimp_config_path_expand_only (const gchar *path,
s = substs[2*i+1];
*n = '\0';
#ifndef _UCRT
strcat (n, s);
#else
strcat_s (n, (length + 1) - (n - expanded), s);
#endif
n += strlen (s);
break;