aboutsummaryrefslogtreecommitdiff
path: root/win32
diff options
context:
space:
mode:
Diffstat (limited to 'win32')
-rw-r--r--win32/mingw.c11
1 files changed, 4 insertions, 7 deletions
diff --git a/win32/mingw.c b/win32/mingw.c
index 28ee81e4e..6e6b20e80 100644
--- a/win32/mingw.c
+++ b/win32/mingw.c
@@ -2461,14 +2461,11 @@ const char * FAST_FUNC get_system_drive(void)
2461 return getenv(BB_SYSTEMROOT) ?: drive; 2461 return getenv(BB_SYSTEMROOT) ?: drive;
2462} 2462}
2463 2463
2464int chdir_system_drive(void) 2464void xchdir_system_drive(void)
2465{ 2465{
2466 const char *sd = get_system_drive(); 2466 char *path = concat_path_file(get_system_drive(), "");
2467 int ret = -1; 2467 xchdir(path);
2468 2468 free(path);
2469 if (*sd)
2470 ret = chdir(auto_string(concat_path_file(sd, "")));
2471 return ret;
2472} 2469}
2473 2470
2474/* 2471/*