[eog-plugins] exif-display: Correctly NULL-ify all pointers to the histogram data
- From: Felix Riemann <friemann src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [eog-plugins] exif-display: Correctly NULL-ify all pointers to the histogram data
- Date: Sun, 27 May 2012 13:22:25 +0000 (UTC)
commit 146580e8cb8bc41da11ee727238fab3ce6d29f30
Author: Felix Riemann <friemann gnome org>
Date: Sat May 26 22:31:27 2012 +0200
exif-display: Correctly NULL-ify all pointers to the histogram data
Fixes double-frees when skipping through images quickly.
https://bugzilla.gnome.org/show_bug.cgi?id=676735
plugins/exif-display/eog-exif-display-plugin.c | 5 +++++
1 files changed, 5 insertions(+), 0 deletions(-)
---
diff --git a/plugins/exif-display/eog-exif-display-plugin.c b/plugins/exif-display/eog-exif-display-plugin.c
index c313053..884f484 100644
--- a/plugins/exif-display/eog-exif-display-plugin.c
+++ b/plugins/exif-display/eog-exif-display-plugin.c
@@ -304,8 +304,13 @@ calculate_histogram (EogExifDisplayPlugin *plugin, EogImage *eog_image)
plugin->histogram_values_red = NULL;
g_free (plugin->histogram_values_green);
+ plugin->histogram_values_green = NULL;
+
g_free (plugin->histogram_values_blue);
+ plugin->histogram_values_blue = NULL;
+
g_free (plugin->histogram_values_rgb);
+ plugin->histogram_values_rgb = NULL;
image_pixbuf = eog_image_get_pixbuf (eog_image);
if (image_pixbuf == NULL) {
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]