[evince] Fix memory leak in EvJobThumbnail



commit 68b2f98c5e326645ba44949225fa7c5cbed8a55f
Author: Eric R. Schulz <eric ers35 com>
Date:   Thu Aug 18 03:08:05 2016 -0400

    Fix memory leak in EvJobThumbnail
    
    Call cairo_surface_destroy() on job->thumbnail_surface.
    
    https://bugzilla.gnome.org/show_bug.cgi?id=770069

 libview/ev-jobs.c |    5 +++++
 1 files changed, 5 insertions(+), 0 deletions(-)
---
diff --git a/libview/ev-jobs.c b/libview/ev-jobs.c
index d338666..dea5aa4 100644
--- a/libview/ev-jobs.c
+++ b/libview/ev-jobs.c
@@ -852,6 +852,11 @@ ev_job_thumbnail_dispose (GObject *object)
                job->thumbnail = NULL;
        }
 
+       if (job->thumbnail_surface) {
+               cairo_surface_destroy (job->thumbnail_surface);
+               job->thumbnail_surface = NULL;
+       }
+
        (* G_OBJECT_CLASS (ev_job_thumbnail_parent_class)->dispose) (object);
 }
 


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]