Bug 944207 - Reset the number of HWC layers on failures before HWC prepare. r=dwilson

This commit is contained in:
Sushil Chauhan 2013-11-29 11:39:39 -08:00
parent 2940d90868
commit de7dd419b8

View File

@ -451,6 +451,7 @@ HwcComposer2D::TryHwComposition()
if (!(fbsurface && fbsurface->lastHandle)) {
LOGD("H/W Composition failed. FBSurface not initialized.");
mList->numHwLayers = 0;
return false;
}
@ -459,6 +460,7 @@ HwcComposer2D::TryHwComposition()
if (idx >= mMaxLayerCount) {
if (!ReallocLayerList() || idx >= mMaxLayerCount) {
LOGE("TryHwComposition failed! Could not add FB layer");
mList->numHwLayers = 0;
return false;
}
}