mirror of
https://github.com/servo/servo.git
synced 2025-06-21 15:49:04 +01:00
Better bindgen error message when files are missing.
This is only slightly more informative because it doesn't give the filename, but I think it's an improvement on the simple unwrap() panic when we try to read a file which isn't there. See also [Gecko bug 1368083](https://bugzilla.mozilla.org/show_bug.cgi?id=1368083).
This commit is contained in:
parent
8db2775ba6
commit
ec49c4d8c8
1 changed files with 2 additions and 1 deletions
|
@ -133,7 +133,8 @@ mod bindings {
|
|||
}
|
||||
|
||||
fn update_last_modified(file: &Path) {
|
||||
let modified = get_modified_time(file).unwrap();
|
||||
let modified = get_modified_time(file)
|
||||
.expect("Couldn't get file modification time");
|
||||
let mut last_modified = LAST_MODIFIED.lock().unwrap();
|
||||
*last_modified = cmp::max(modified, *last_modified);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue