diff options
author | bors-servo <lbergstrom+bors@mozilla.com> | 2016-08-08 09:59:40 -0500 |
---|---|---|
committer | GitHub <noreply@github.com> | 2016-08-08 09:59:40 -0500 |
commit | c420a870c1b1bca7e740e8bb737ef2bcdb1a139d (patch) | |
tree | 57440e3444257f8a0c324751e359b5d3248f4295 /components/gfx/font_cache_thread.rs | |
parent | 3ae94fca708bb7783c9e0e356f58521fc19fcdbf (diff) | |
parent | dc3c46908512dbd90ded414df9d168ca67cc416b (diff) | |
download | servo-c420a870c1b1bca7e740e8bb737ef2bcdb1a139d.tar.gz servo-c420a870c1b1bca7e740e8bb737ef2bcdb1a139d.zip |
Auto merge of #12770 - nox:intermittent-study, r=SimonSapin
Use expect calls to investigate #12540 and #12288
<!-- Reviewable:start -->
This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/12770)
<!-- Reviewable:end -->
Diffstat (limited to 'components/gfx/font_cache_thread.rs')
-rw-r--r-- | components/gfx/font_cache_thread.rs | 18 |
1 files changed, 12 insertions, 6 deletions
diff --git a/components/gfx/font_cache_thread.rs b/components/gfx/font_cache_thread.rs index 314def3b2cf..4ba4af2b39f 100644 --- a/components/gfx/font_cache_thread.rs +++ b/components/gfx/font_cache_thread.rs @@ -423,10 +423,13 @@ impl FontCacheThread { pub fn find_font_template(&self, family: FontFamily, desc: FontTemplateDescriptor) -> Option<FontTemplateInfo> { - let (response_chan, response_port) = ipc::channel().unwrap(); - self.chan.send(Command::GetFontTemplate(family, desc, response_chan)).unwrap(); + let (response_chan, response_port) = + ipc::channel().expect("failed to create IPC channel"); + self.chan.send(Command::GetFontTemplate(family, desc, response_chan)) + .expect("failed to send message to font cache thread"); - let reply = response_port.recv().unwrap(); + let reply = response_port.recv() + .expect("failed to receive response to font request"); match reply { Reply::GetFontTemplateReply(data) => { @@ -437,10 +440,13 @@ impl FontCacheThread { pub fn last_resort_font_template(&self, desc: FontTemplateDescriptor) -> FontTemplateInfo { - let (response_chan, response_port) = ipc::channel().unwrap(); - self.chan.send(Command::GetLastResortFontTemplate(desc, response_chan)).unwrap(); + let (response_chan, response_port) = + ipc::channel().expect("failed to create IPC channel"); + self.chan.send(Command::GetLastResortFontTemplate(desc, response_chan)) + .expect("failed to send message to font cache thread"); - let reply = response_port.recv().unwrap(); + let reply = response_port.recv() + .expect("failed to receive response to font request"); match reply { Reply::GetFontTemplateReply(data) => { |