Commit 8d81f226 authored by Dom Lachowicz's avatar Dom Lachowicz

get rid of unecessary 0-ing of data

parent c65b3e9b
......@@ -377,7 +377,7 @@ void rsvg_cairo_render_image (RsvgDrawingCtx *ctx, const GdkPixbuf * pixbuf,
else
format = CAIRO_FORMAT_ARGB32;
cairo_pixels = g_malloc0 (4 * width * height);
cairo_pixels = g_malloc (4 * width * height);
surface = cairo_image_surface_create_for_data ((unsigned char *)cairo_pixels,
format,
width, height, 4 * width);
......
......@@ -134,7 +134,7 @@ static GdkPixbuf * _rsvg_handle_get_pixbuf (RsvgHandle *handle)
rsvg_handle_get_dimensions (handle, &dimensions);
rowstride = dimensions.width * 4;
pixels = g_new0(guint8, dimensions.width * dimensions.height * 4);
pixels = g_new(guint8, dimensions.width * dimensions.height * 4);
surface = cairo_image_surface_create_for_data (pixels,
CAIRO_FORMAT_ARGB32,
dimensions.width, dimensions.height,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment