Krzysztof Halasa <[email protected]> writes:

>> Something like the attached patch would be preferred (there's no need to
>> set up the overlay if the destination area isn't going to be visible
>> anyway).
>
> []
>
>> --- a/src/smi_video.c
>> +++ b/src/smi_video.c
>> @@ -1060,7 +1060,7 @@ SMI_PutVideo(
>>      if(!xf86_crtc_clip_video_helper(pScrn, &crtc, crtcConf->crtc[0], 
>> &dstBox, &x1, &x2, &y1, &y2, clipBoxes, width, height))
>>      LEAVE(Success);
>>  
>> -    if(pSmi->Dualhead && crtc == crtcConf->crtc[1])
>> +    if(crtc != crtcConf->crtc[0])
> ^^^^^^^^^^^^^^^
>>      LEAVE(Success);
>>  
>>      /* Transform dstBox to the CRTC coordinates */
>> @@ -1521,6 +1521,9 @@ SMI_PutImage(
>>                                       width, height))
>>          LEAVE(Success);
>>  
>> +    if (!crtc)
>> +        LEAVE(Success);
>> +
>>      /* Transform dstBox to the CRTC coordinates */
>>      dstBox.x1 -= crtc->x;
>>      dstBox.y1 -= crtc->y;
>> @@ -2468,6 +2471,9 @@ SMI_DisplaySurface(
>>                                  &x1, &x2, &y1, &y2, clipBoxes, 
>> surface->width, surface->height))
>>      LEAVE(Success);
>>  
>> +    if(!crtc)
> ^^^^^^^^^^^^^^^
>> +    LEAVE(Success);
>> +
>>      /* Transform dstBox to the CRTC coordinates */
>>      dstBox.x1 -= crtc->x;
>>      dstBox.y1 -= crtc->y;
>>
>
> It looks like it's working fine, no more crashes with out of screen
> Xvideo. You may add that Tested-by: Krzysztof Halasa <[email protected]> tag
> to the commit msg. BTW I don't think you need to ask "testers" for the
> complete "tested-by", you can add it yourself, you only need testers to
> actually test the patch - same with e.g. "acked-by" :-)
>
I just wanted to warn you that your personal info was going to end up in
the commit logs. ;-)

> Also, you may want to insert a space after these two "if".
>
> Thanks.

Attachment: pgpC7ExN7nqHM.pgp
Description: PGP signature

_______________________________________________
[email protected]: X.Org support
Archives: http://lists.freedesktop.org/archives/xorg
Info: http://lists.freedesktop.org/mailman/listinfo/xorg
Your subscription address: [email protected]

Reply via email to