about summary refs log tree commit diff
path: root/src/bootstrap
diff options
context:
space:
mode:
authorTanner Davies <tanner.e.davies@gmail.com>2022-11-07 15:27:42 -0700
committerTanner Davies <tanner.e.davies@gmail.com>2022-11-07 15:27:42 -0700
commit66e8a296403e80ea50b2217d40e7a31fbd2f2158 (patch)
treef0a0d8d34fc336a81819bfba444972c3a86dbb50 /src/bootstrap
parent13d4c61b5f732f17b66c7610588e113844fc5e08 (diff)
downloadrust-66e8a296403e80ea50b2217d40e7a31fbd2f2158.tar.gz
rust-66e8a296403e80ea50b2217d40e7a31fbd2f2158.zip
Only set config.config to None when using default path
Diffstat (limited to 'src/bootstrap')
-rw-r--r--src/bootstrap/config.rs3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/bootstrap/config.rs b/src/bootstrap/config.rs
index c086d248e5c..ba50ce9ec24 100644
--- a/src/bootstrap/config.rs
+++ b/src/bootstrap/config.rs
@@ -926,8 +926,10 @@ impl Config {
         // Give a hard error if `--config` or `RUST_BOOTSTRAP_CONFIG` are set to a missing path,
         // but not if `config.toml` hasn't been created.
         let mut toml = if !using_default_path || toml_path.exists() {
+            config.config = Some(toml_path.clone());
             get_toml(&toml_path)
         } else {
+            config.config = None;
             TomlConfig::default()
         };
 
@@ -942,7 +944,6 @@ impl Config {
         }
 
         config.changelog_seen = toml.changelog_seen;
-        config.config = if toml_path.exists() { Some(toml_path) } else { None };
 
         let build = toml.build.unwrap_or_default();