Convert LayoutContext.image_cache from @mut to MutexArc

LocalImageCache isn't Freeze so we have to use unsafe_access,
which exists for MutexArc and not RWArc.
This commit is contained in:
Keegan McAllister 2013-12-05 17:44:47 -08:00
parent 94b70e25e1
commit dda6d2b53c
5 changed files with 30 additions and 14 deletions

View file

@ -209,7 +209,7 @@ impl<'self> FlowConstructor<'self> {
Some(url) => {
// FIXME(pcwalton): The fact that image boxes store the cache within them makes
// little sense to me.
Some(ImageBoxInfo::new(url, self.layout_context.image_cache))
Some(ImageBoxInfo::new(url, self.layout_context.image_cache.clone()))
}
}
}