[cairo-commit] cairo/src cairo-surface.c, 1.95, 1.96 cairoint.h, 1.200, 1.201

Owen Taylor commit at pdx.freedesktop.org
Mon Aug 22 01:53:58 EST 2005


Committed by: otaylor

Update of /cvs/cairo/cairo/src
In directory gabe:/tmp/cvs-serv15758/src

Modified Files:
	cairo-surface.c cairoint.h 
Log Message:
2005-08-21  Owen Taylor  <otaylor at redhat.com>

        * src/cairo-surface.c (_cairo_surface_clone_similar): Fix the
        handling of backend->clone_similar == NULL. (#4161,
        Christian Biesinger)


Index: cairo-surface.c
===================================================================
RCS file: /cvs/cairo/cairo/src/cairo-surface.c,v
retrieving revision 1.95
retrieving revision 1.96
diff -u -d -r1.95 -r1.96
--- cairo-surface.c	21 Aug 2005 15:24:41 -0000	1.95
+++ cairo-surface.c	21 Aug 2005 15:53:56 -0000	1.96
@@ -690,11 +690,12 @@
     if (surface->finished)
 	return CAIRO_STATUS_SURFACE_FINISHED;
 
-    if (surface->backend->clone_similar) {
-	status = surface->backend->clone_similar (surface, src, clone_out);
-	if (status != CAIRO_INT_STATUS_UNSUPPORTED)
- 	    return status;
-    }
+    if (surface->backend->clone_similar == NULL)
+	return CAIRO_INT_STATUS_UNSUPPORTED;
+      
+    status = surface->backend->clone_similar (surface, src, clone_out);
+    if (status != CAIRO_INT_STATUS_UNSUPPORTED)
+	return status;
 
     status = _cairo_surface_acquire_source_image (src, &image, &image_extra);
     if (status != CAIRO_STATUS_SUCCESS)

Index: cairoint.h
===================================================================
RCS file: /cvs/cairo/cairo/src/cairoint.h,v
retrieving revision 1.200
retrieving revision 1.201
diff -u -d -r1.200 -r1.201
--- cairoint.h	20 Aug 2005 06:05:13 -0000	1.200
+++ cairoint.h	21 Aug 2005 15:53:56 -0000	1.201
@@ -689,7 +689,7 @@
 				 cairo_image_surface_t  *image,
 				 cairo_rectangle_t      *image_rect,
 				 void                   *image_extra);
-	
+
     cairo_status_t
     (*clone_similar)            (void                   *surface,
 				 cairo_surface_t        *src,



More information about the cairo-commit mailing list