This should prevent a crash when something like Cairo tries to composite a solid picture.
Signed-off-by: Connor Behan <[email protected]> --- src/smi_exa.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/smi_exa.c b/src/smi_exa.c index 70298ed..67a6fdd 100644 --- a/src/smi_exa.c +++ b/src/smi_exa.c @@ -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); -- 2.5.0 _______________________________________________ [email protected]: X.Org development Archives: http://lists.x.org/archives/xorg-devel Info: http://lists.x.org/mailman/listinfo/xorg-devel
