Skip to content

Commit 6329eaa

Browse files
committed
fixup! mingw: Prepare the TMP environment variable for shell scripts
This change is not actually needed any longer to pass the test suite. Signed-off-by: Johannes Schindelin <[email protected]>
1 parent 4f38e72 commit 6329eaa

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

compat/mingw.c

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2735,8 +2735,14 @@ void mingw_startup()
27352735
__argv[0] = wcstoutfdup_startup(buffer, _wpgmptr, maxlen);
27362736
for (i = 1; i < argc; i++)
27372737
__argv[i] = wcstoutfdup_startup(buffer, wargv[i], maxlen);
2738-
for (i = 0; wenv[i]; i++)
2738+
for (i = 0; wenv[i]; i++) {
27392739
environ[i] = wcstoutfdup_startup(buffer, wenv[i], maxlen);
2740+
if (!strncasecmp(environ[i], "MSYS2_TZ=", 9)) {
2741+
char *to_free = environ[i];
2742+
environ[i] = xstrdup(to_free + 6);
2743+
free(to_free);
2744+
}
2745+
}
27402746
environ[i] = NULL;
27412747
free(buffer);
27422748

0 commit comments

Comments
 (0)