Bug 1000634 - Only ask for the composer if we have a compositable host, when doing fencing. r=sikeda,nsilva

This commit is contained in:
Milan Sreckovic 2014-09-08 14:05:41 -04:00
Родитель 773f767321
Коммит 0c06648d5e
1 изменённых файлов: 3 добавлений и 1 удалений

Просмотреть файл

@ -1393,7 +1393,9 @@ CompositorOGL::SetFBAcquireFence(Layer* aLayer)
// Set FBAcquireFence as tiles' ReleaseFence on TiledLayerComposer.
TiledLayerComposer* composer = nullptr;
LayerComposite* shadow = aLayer->AsLayerComposite();
if (shadow) {
// Only ask for the composer if we have a compositable host. Timing
// may make it so that we don't - see bug 1000634.
if (shadow && shadow->GetCompositableHost()) {
composer = shadow->GetTiledLayerComposer();
if (composer) {
composer->SetReleaseFence(new android::Fence(GetGonkDisplay()->GetPrevFBAcquireFd()));