Auto merge of #11368 - izgzhen:fix-filemanager-exit, r=asajeffrey

Fix FileManager thread panic and other misc improvements

- [x] `./mach build -d` does not report any errors
- [x] `./mach test-tidy --faster` does not report any errors
- [x] There are tests for these changes

Changes:

- Add shut down logic for FileManager thread
- Add an unit test for filemanager_thread

<!-- Reviewable:start -->
---
This change is [<img src="https://reviewable.io/review_button.svg" height="35" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/11368)
<!-- Reviewable:end -->
This commit is contained in:
bors-servo 2016-05-24 22:17:15 -05:00
commit 0b64586bf5
6 changed files with 46 additions and 3 deletions

View file

@ -51,8 +51,6 @@ impl File {
pub fn new_from_selected(window: &Window, selected: SelectedFile) -> Root<File> {
let name = DOMString::from(selected.filename.to_str().expect("File name encoding error"));
// FIXME: fix this after PR #11221 is landed
let id = selected.id;
let slice = DataSlice::empty();
let global = GlobalRef::Window(window);