Skip to content

Commit

Permalink
Fix RUSTC_LOG handling
Browse files Browse the repository at this point in the history
Rustc was incorrectly reading the value of `RUSTC_LOG` as the
environment vairable with the logging configuration, rather than the
logging configuration itself.
  • Loading branch information
matthewjasper committed Oct 10, 2021
1 parent 0c87288 commit 9e6e89a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion compiler/rustc_driver/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1259,7 +1259,7 @@ pub fn init_env_logger(env: &str) {
};

let filter = match std::env::var(env) {
Ok(env) => EnvFilter::from_env(env),
Ok(env) => EnvFilter::new(env),
_ => EnvFilter::default().add_directive(filter::Directive::from(LevelFilter::WARN)),
};

Expand Down

0 comments on commit 9e6e89a

Please sign in to comment.