Commit a4e406c2 authored by Connor Behan's avatar Connor Behan
Browse files

Check for drawables before compositing

This should prevent a crash when something like Cairo tries to composite
a solid picture.
Signed-off-by: Connor Behan's avatarConnor Behan <>
parent 70d3d3a3
......@@ -623,6 +623,10 @@ SMI_PrepareComposite(int op, PicturePtr pSrcPicture, PicturePtr pMaskPicture, Pi
ScrnInfoPtr pScrn = xf86ScreenToScrn(pDst->drawable.pScreen);
SMIPtr pSmi = SMIPTR(pScrn);
if (!pSrc) return FALSE;
if (!pSrcPicture->pDrawable) return FALSE;
int src_pitch = exaGetPixmapPitch(pSrc) / (pSrc->drawable.bitsPerPixel >> 3);
int dst_pitch = exaGetPixmapPitch(pDst) / (pDst->drawable.bitsPerPixel >> 3);
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment