mirror of
https://github.com/servo/servo.git
synced 2025-06-23 16:44:33 +01:00
auto merge of #2252 : mbrubeck/servo/1778-borrow-layer, r=larsbergstrom
Fixes a crash in ContainerLayer::remove_child (#1778). r? @larsbergstrom
This commit is contained in:
commit
afae6a3c71
1 changed files with 4 additions and 3 deletions
|
@ -376,10 +376,11 @@ impl IOCompositor {
|
|||
self.opts.tile_size,
|
||||
self.opts.cpu_painting);
|
||||
|
||||
match *self.root_layer.first_child.borrow() {
|
||||
let first_child = self.root_layer.first_child.borrow().clone();
|
||||
match first_child {
|
||||
None => {}
|
||||
Some(ref old_layer) => {
|
||||
ContainerLayer::remove_child(self.root_layer.clone(), old_layer.clone())
|
||||
Some(old_layer) => {
|
||||
ContainerLayer::remove_child(self.root_layer.clone(), old_layer)
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue