0001-xlib-shm-Fix-memory-leak.patch: Fix a memory leak with shm image
surfaces. (#882976)
This commit is contained in:
parent
558370767e
commit
030ac7e907
29
0001-xlib-shm-Fix-memory-leak.patch
Normal file
29
0001-xlib-shm-Fix-memory-leak.patch
Normal file
@ -0,0 +1,29 @@
|
||||
From 84338157ab9e06fa89785af14772e046e2f9e747 Mon Sep 17 00:00:00 2001
|
||||
From: Adam Jackson <ajax@redhat.com>
|
||||
Date: Tue, 18 Dec 2012 12:49:19 -0500
|
||||
Subject: [PATCH] xlib/shm: Fix memory leak
|
||||
|
||||
Despite subclassing image surfaces, we never called down to the image
|
||||
surface destructor, so we leaked a pixman_image_t every time.
|
||||
|
||||
Signed-off-by: Adam Jackson <ajax@redhat.com>
|
||||
---
|
||||
src/cairo-xlib-surface-shm.c | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/src/cairo-xlib-surface-shm.c b/src/cairo-xlib-surface-shm.c
|
||||
index b03dd83..684d7e8 100644
|
||||
--- a/src/cairo-xlib-surface-shm.c
|
||||
+++ b/src/cairo-xlib-surface-shm.c
|
||||
@@ -679,7 +679,7 @@ _cairo_xlib_shm_surface_finish (void *abstract_surface)
|
||||
cairo_list_del (&shm->link);
|
||||
|
||||
cairo_device_release (&display->base);
|
||||
- return CAIRO_STATUS_SUCCESS;
|
||||
+ return _cairo_image_surface_finish (abstract_surface);
|
||||
}
|
||||
|
||||
static const cairo_surface_backend_t cairo_xlib_shm_surface_backend = {
|
||||
--
|
||||
1.8.0.1
|
||||
|
@ -5,7 +5,7 @@
|
||||
Summary: A 2D graphics library
|
||||
Name: cairo
|
||||
Version: 1.12.8
|
||||
Release: 1%{?dist}
|
||||
Release: 2%{?dist}
|
||||
URL: http://cairographics.org
|
||||
#VCS: git:git://git.freedesktop.org/git/cairo
|
||||
#Source0: http://cairographics.org/snapshots/%{name}-%{version}.tar.gz
|
||||
@ -15,6 +15,7 @@ Group: System Environment/Libraries
|
||||
|
||||
Patch0: 0001-xlib-Don-t-crash-when-swapping-a-0-sized-glyph.patch
|
||||
Patch1: 0002-xcb-Don-t-crash-when-swapping-a-0-sized-glyph.patch
|
||||
Patch2: 0001-xlib-shm-Fix-memory-leak.patch
|
||||
|
||||
BuildRequires: pkgconfig
|
||||
BuildRequires: libXrender-devel
|
||||
@ -94,6 +95,7 @@ This package contains tools for working with the cairo graphics library.
|
||||
%setup -q
|
||||
%patch0 -p1 -b .xlib-swap
|
||||
%patch1 -p1 -b .xcb-swap
|
||||
%patch2 -p1 -b .shm-leak
|
||||
|
||||
%build
|
||||
%configure --disable-static \
|
||||
@ -177,6 +179,10 @@ rm $RPM_BUILD_ROOT%{_libdir}/*.la
|
||||
%{_libdir}/cairo/
|
||||
|
||||
%changelog
|
||||
* Tue Dec 18 2012 Adam Jackson <ajax@redhat.com> 1.12.8-2
|
||||
- 0001-xlib-shm-Fix-memory-leak.patch: Fix a memory leak with shm image
|
||||
surfaces. (#882976)
|
||||
|
||||
* Mon Nov 5 2012 Matthias Clasen <mclasen@redhat.com> - 1.12.8-1
|
||||
- Update to 1.12.8, including a fix for screenshots in fallback mode
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user