From 7c5a2adfa54cb3e42d4f58c5a08ea54063cb84c7 Mon Sep 17 00:00:00 2001 From: Bart House Date: Sun, 3 Nov 2019 14:07:11 -0800 Subject: [PATCH] Lock TROUBLEPREFIX after parsing sysconf. --- sys/winnt/windmain.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/sys/winnt/windmain.c b/sys/winnt/windmain.c index c14e3e7af..d226b26f1 100644 --- a/sys/winnt/windmain.c +++ b/sys/winnt/windmain.c @@ -410,7 +410,12 @@ _CrtSetReportFile(_CRT_ASSERT, _CRTDBG_FILE_STDERR);*/ check_recordfile((char *) 0); iflags.windowtype_deferred = TRUE; copy_sysconf_content(); - initoptions(); + initoptions(); + + /* Now that sysconf has had a chance to set the TROUBLEPREFIX, don't + allow it to be changed from here on out. */ + fqn_prefix_locked[TROUBLEPREFIX] = TRUE; + copy_config_content(); process_options(argc, argv);