]> git.lizzy.rs Git - rust.git/commitdiff
bin: Canonicalize path before looking for project file
authorKamal Marhubi <kamal@marhubi.com>
Sun, 31 Jan 2016 07:01:54 +0000 (02:01 -0500)
committerKamal Marhubi <kamal@marhubi.com>
Sun, 31 Jan 2016 07:01:54 +0000 (02:01 -0500)
src/bin/rustfmt.rs

index a8a19d96bc775af9028d1057355b0a917f2ce703..187b48ec1965d6a4a2922557d90189e765f055d9 100644 (file)
@@ -51,9 +51,7 @@ fn lookup_project_file(input_file: &Path) -> io::Result<PathBuf> {
         input_file.to_path_buf()
     };
 
-    // FIXME: We should canonize path to properly handle its parents,
-    // but `canonicalize` function is unstable now (recently added API)
-    // current = try!(fs::canonicalize(current));
+    current = try!(fs::canonicalize(current));
 
     loop {
         let config_file = current.join("rustfmt.toml");