From f6434a9790edb130c9f2a0c8d67ee9cdd5d031c9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Emilio=20Cobos=20=C3=81lvarez?= Date: Fri, 13 May 2016 01:10:46 +0200 Subject: [PATCH] gfx: Add expect messages to FontCacheThread::exit() One of these two unwraps is the one that is causing most occurrences of #8815. I'd go with removing the second unwrap entirely, but let's get some debug info first, since it might probably be a race. --- components/gfx/font_cache_thread.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/components/gfx/font_cache_thread.rs b/components/gfx/font_cache_thread.rs index 5a98e7175488..558d8b170a62 100644 --- a/components/gfx/font_cache_thread.rs +++ b/components/gfx/font_cache_thread.rs @@ -438,8 +438,8 @@ impl FontCacheThread { pub fn exit(&self) { let (response_chan, response_port) = ipc::channel().unwrap(); - self.chan.send(Command::Exit(response_chan)).unwrap(); - response_port.recv().unwrap(); + self.chan.send(Command::Exit(response_chan)).expect("Couldn't send FontCacheThread exit message"); + response_port.recv().expect("Couldn't receive FontCacheThread reply"); } }