Skip to content

Commit 3b22352

Browse files
committed
Fix bug with getting parent directories in lookup_conf_file
1 parent 9e53b65 commit 3b22352

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

clippy_lints/src/utils/conf.rs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -478,7 +478,8 @@ pub fn lookup_conf_file() -> io::Result<(Option<PathBuf>, Vec<String>)> {
478478
// If neither of those exist, use ".".
479479
let mut current = env::var_os("CLIPPY_CONF_DIR")
480480
.or_else(|| env::var_os("CARGO_MANIFEST_DIR"))
481-
.map_or_else(|| PathBuf::from("."), PathBuf::from);
481+
.map_or_else(|| PathBuf::from("."), PathBuf::from)
482+
.canonicalize()?;
482483

483484
let mut found_config: Option<PathBuf> = None;
484485
let mut warnings = vec![];

0 commit comments

Comments
 (0)