[cairo-commit] 2 commits - boilerplate/cairo-boilerplate-pdf.c src/cairo-os2-surface.c

Benjamin Otte company at kemper.freedesktop.org
Mon May 3 01:22:18 PDT 2010


 boilerplate/cairo-boilerplate-pdf.c |    3 +++
 src/cairo-os2-surface.c             |    2 +-
 2 files changed, 4 insertions(+), 1 deletion(-)

New commits:
commit c10a5a9fb0463f254fb607a2260b540256f888cc
Author: Dave Yeo <daveryeo at telus.net>
Date:   Mon May 3 10:20:51 2010 +0200

    os2: Fix get_extents() segfaulting.
    
    bed2701e1c89095878d549cbca8f22d84f3dda3c removed one line too much.

diff --git a/src/cairo-os2-surface.c b/src/cairo-os2-surface.c
index 6d97996..4ca88b7 100644
--- a/src/cairo-os2-surface.c
+++ b/src/cairo-os2-surface.c
@@ -721,7 +721,7 @@ static cairo_bool_t
 _cairo_os2_surface_get_extents (void                    *abstract_surface,
                                 cairo_rectangle_int_t   *rectangle)
 {
-    cairo_os2_surface_t *local_os2_surface;
+    cairo_os2_surface_t *local_os2_surface = abstract_surface;
 
     rectangle->x = 0;
     rectangle->y = 0;
commit 9df81fe4d3f0ccc5632d0e84e920fe1c448bd531
Author: Benjamin Otte <otte at redhat.com>
Date:   Sun May 2 19:59:26 2010 +0200

    boilerplate: don't compile pdf test code when pdf is not tested
    
    Avoids gcc warnings when libpoppler version isn't good enough.

diff --git a/boilerplate/cairo-boilerplate-pdf.c b/boilerplate/cairo-boilerplate-pdf.c
index 8459f58..62e2536 100644
--- a/boilerplate/cairo-boilerplate-pdf.c
+++ b/boilerplate/cairo-boilerplate-pdf.c
@@ -26,6 +26,8 @@
 
 #include "cairo-boilerplate-private.h"
 
+#if CAIRO_CAN_TEST_PDF_SURFACE
+
 #include <cairo-pdf.h>
 #include <cairo-pdf-surface-private.h>
 #include <cairo-paginated-surface-private.h>
@@ -230,6 +232,7 @@ _cairo_boilerplate_pdf_force_fallbacks (cairo_surface_t *abstract_surface,
     surface = (cairo_pdf_surface_t*) paginated->target;
     surface->force_fallbacks = TRUE;
 }
+#endif
 
 static const cairo_boilerplate_target_t targets[] = {
 #if CAIRO_CAN_TEST_PDF_SURFACE


More information about the cairo-commit mailing list