diff options
author | Maarten Maathuis <madman2003@gmail.com> | 2009-03-01 01:15:28 +0100 |
---|---|---|
committer | Maarten Maathuis <madman2003@gmail.com> | 2009-03-04 16:51:09 +0100 |
commit | 3ea3d505e8128ab3e878edcef697fd5656b0c917 (patch) | |
tree | c70da078e272978cd2f76af7765b09dc8ab1e48d | |
parent | 10334cf7e64e2e633cd507f2aa216027e840c8e5 (diff) |
exa: avoid a potential Prepare/FinishAccess inbalance.
-rw-r--r-- | exa/exa_unaccel.c | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/exa/exa_unaccel.c b/exa/exa_unaccel.c index d16ecf79e..4279c877c 100644 --- a/exa/exa_unaccel.c +++ b/exa/exa_unaccel.c @@ -405,7 +405,7 @@ ExaCheckComposite (CARD8 op, if (!miComputeCompositeRegion (®ion, pSrc, pMask, pDst, xSrc, ySrc, xMask, yMask, xDst, yDst, width, height)) - return; + goto skip; exaGetDrawableDeltas (pDst->pDrawable, exaGetDrawablePixmap(pDst->pDrawable), @@ -450,16 +450,18 @@ ExaCheckComposite (CARD8 op, #endif /* RENDER */ if (pMask && pMask->pDrawable != NULL) exaFinishAccess (pMask->pDrawable, EXA_PREPARE_MASK); - if (pMask && pMask->alphaMap && pMask->alphaMap->pDrawable) - exaFinishAccess(pMask->alphaMap->pDrawable, EXA_PREPARE_AUX_MASK); if (pSrc->pDrawable != NULL) exaFinishAccess (pSrc->pDrawable, EXA_PREPARE_SRC); - if (pSrc->alphaMap && pSrc->alphaMap->pDrawable) - exaFinishAccess(pSrc->alphaMap->pDrawable, EXA_PREPARE_AUX_SRC); exaFinishAccess (pDst->pDrawable, EXA_PREPARE_DEST); if (pDst->alphaMap && pDst->alphaMap->pDrawable) exaFinishAccess(pDst->alphaMap->pDrawable, EXA_PREPARE_AUX_DEST); +skip: + if (pSrc->alphaMap && pSrc->alphaMap->pDrawable) + exaFinishAccess(pSrc->alphaMap->pDrawable, EXA_PREPARE_AUX_SRC); + if (pMask && pMask->alphaMap && pMask->alphaMap->pDrawable) + exaFinishAccess(pMask->alphaMap->pDrawable, EXA_PREPARE_AUX_MASK); + REGION_UNINIT(pScreen, ®ion); } |