[Xfce4-commits] [xfce/thunar] 01/01: Fix potential buffer overflow (Bug #12444)

noreply at xfce.org noreply at xfce.org
Mon Jan 29 09:56:39 CET 2018


This is an automated email from the git hooks/post-receive script.

a   l   e   x       p   u   s   h   e   d       a       c   o   m   m   i   t       t   o       b   r   a   n   c   h       x   f   c   e   -   4   .   1   2   
   in repository xfce/thunar.

commit 6d8b604cad217884d884a641bf7c2e19b7ca36f8
Author: Mikhail Efremov <mikhefr at gmail.com>
Date:   Mon Jan 29 09:52:41 2018 +0100

    Fix potential buffer overflow (Bug #12444)
---
 thunar/thunar-gdk-extensions.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/thunar/thunar-gdk-extensions.c b/thunar/thunar-gdk-extensions.c
index 50ecb4a..775eca3 100644
--- a/thunar/thunar-gdk-extensions.c
+++ b/thunar/thunar-gdk-extensions.c
@@ -75,7 +75,7 @@ thunar_gdk_cairo_create_surface (const GdkPixbuf *pixbuf)
 
   /* prepare pixel data and surface */
   cairo_stride = cairo_format_stride_for_width (format, width);
-  cairo_pixels = g_malloc (height * cairo_stride);
+  cairo_pixels = g_malloc_n (height, cairo_stride);
   surface = cairo_image_surface_create_for_data (cairo_pixels, format,
                                                  width, height, cairo_stride);
   cairo_surface_set_user_data (surface, &cairo_key, cairo_pixels, g_free);

-- 
To stop receiving notification emails like this one, please contact
the administrator of this repository.


More information about the Xfce4-commits mailing list