Fix logging the file name on windows

This commit is contained in:
Thinkofdeath 2015-10-06 23:04:37 +01:00
parent 7bca6e55cf
commit 526aaffec3
1 changed files with 1 additions and 1 deletions

View File

@ -202,7 +202,7 @@ impl Console {
}
fn log(&mut self, record: &log::LogRecord) {
let mut file = record.location().file();
let mut file = &record.location().file().replace("\\", "/")[..];
if let Some(pos) = file.rfind("src/") {
file = &file[pos + 4..];
}