[cairo] _cairo_surface_clone_similar and missing clone_similar in backend

Christian Biesinger cbiesinger at web.de
Sat Aug 6 17:27:13 PDT 2005


Hi,
_cairo_surface_clone_similar seems to do its clone_similar checking 
inconsistently. If clone_similar is null, it is first checked here:
     687     if (surface->backend->clone_similar) {
     688         status = surface->backend->clone_similar (surface, src, 
clone_out);
     689         if (status != CAIRO_INT_STATUS_UNSUPPORTED)
     690             return status;
     691     }

But the fallback code does not nullcheck:
     697     status = surface->backend->clone_similar (surface, 
&image->base, clone_out);

Seems to me like that'd crash if the backend does not implement that 
function...

-biesi
-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/x-pkcs7-signature
Size: 4792 bytes
Desc: S/MIME Cryptographic Signature
Url : http://lists.freedesktop.org/archives/cairo/attachments/20050807/d8b9fd67/smime.bin


More information about the cairo mailing list