Index: cc/trees/layer_tree_host_impl.cc |
diff --git a/cc/trees/layer_tree_host_impl.cc b/cc/trees/layer_tree_host_impl.cc |
index a10d46b423c1e77b354494db0706179ec91ceea2..cc6f1be43d0da1a9ea89a82e0d203ab130e2c30e 100644 |
--- a/cc/trees/layer_tree_host_impl.cc |
+++ b/cc/trees/layer_tree_host_impl.cc |
@@ -1818,8 +1818,10 @@ void LayerTreeHostImpl::ActivateSyncTree() { |
if (time_source_client_adapter_ && time_source_client_adapter_->Active()) |
DCHECK(active_tree_->root_layer()); |
- page_scale_animation_ = active_tree_->TakePageScaleAnimation(); |
- if (page_scale_animation_) { |
+ scoped_ptr<PageScaleAnimation> page_scale_animation = |
+ active_tree_->TakePageScaleAnimation(); |
+ if (page_scale_animation) { |
+ page_scale_animation_ = page_scale_animation.Pass(); |
SetNeedsAnimate(); |
client_->SetNeedsCommitOnImplThread(); |
client_->RenewTreePriority(); |