aboutsummaryrefslogtreecommitdiffstats
path: root/com32/elflink/ldlinux/readconfig.c
diff options
context:
space:
mode:
Diffstat (limited to 'com32/elflink/ldlinux/readconfig.c')
-rw-r--r--com32/elflink/ldlinux/readconfig.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/com32/elflink/ldlinux/readconfig.c b/com32/elflink/ldlinux/readconfig.c
index 156acf57..f4f599f4 100644
--- a/com32/elflink/ldlinux/readconfig.c
+++ b/com32/elflink/ldlinux/readconfig.c
@@ -1356,15 +1356,15 @@ static int parse_one_config(const char *filename)
if (fd < 0)
return fd;
- f = fdopen(fd, mode);
- parse_config_file(f);
-
if (config_cwd[0]) {
if (chdir(config_cwd) < 0)
printf("Failed to chdir to %s\n", config_cwd);
config_cwd[0] = '\0';
}
+ f = fdopen(fd, mode);
+ parse_config_file(f);
+
return 0;
}