summaryrefslogtreecommitdiff
path: root/src/cairo-png.c
diff options
context:
space:
mode:
authorChris Wilson <chris@chris-wilson.co.uk>2008-11-07 13:26:46 +0000
committerChris Wilson <chris@chris-wilson.co.uk>2008-11-07 19:30:33 +0000
commit2554d1759835a174b89107808d81d044c3e2e098 (patch)
tree0b18975ffbadbaa47bdcccb68f6bacabbc99306f /src/cairo-png.c
parentff0bd64e9436026f11e85eafcd74e9a0131c8b9f (diff)
downloadcairo-2554d1759835a174b89107808d81d044c3e2e098.tar.gz
[surface] Pass a separate closure for the mime-type destroy notifier.
A limitation of the current API was that the destroy notifier was called on the mime-data block. This prevents the user from passing in a pointer to a managed block, for example a mime-data block belonging to a ref-counted object. We can overcome this by allowing the user to specify the closure to be used with the destroy notifier.
Diffstat (limited to 'src/cairo-png.c')
-rw-r--r--src/cairo-png.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/cairo-png.c b/src/cairo-png.c
index a130ba25d..e8f61b5da 100644
--- a/src/cairo-png.c
+++ b/src/cairo-png.c
@@ -662,7 +662,8 @@ read_png (struct png_read_closure_t *png_closure)
CAIRO_MIME_TYPE_PNG,
mime_data,
mime_data_length,
- free);
+ free,
+ mime_data);
if (status) {
free (mime_data);
cairo_surface_destroy (surface);