[SCM] MLT multimedia framework packaging branch, master, updated. debian/0.8.0-3-2-g050375f
Patrick Matthäi
pmatthaei at alioth.debian.org
Tue Aug 28 18:36:05 UTC 2012
Gitweb-URL: http://git.debian.org/?p=pkg-kde/krap/mlt.git;a=commitdiff;h=fcd573b
The following commit has been merged in the master branch:
commit fcd573bbcdb3fc8c085549be491b2814be5766c9
Author: Patrick Matthäi <pmatthaei at debian.org>
Date: Tue Aug 28 20:31:50 2012 +0200
* Add upstream patch 04-cache-memory-leak, which fixes a memory leak when
using mlt_cache for frames.
---
debian/changelog | 7 ++++++
debian/patches/04-cache-memory-leak.diff | 35 ++++++++++++++++++++++++++++++
debian/patches/series | 1 +
3 files changed, 43 insertions(+), 0 deletions(-)
diff --git a/debian/changelog b/debian/changelog
index 888f967..9c93230 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,10 @@
+mlt (0.8.0-4) UNRELEASED; urgency=low
+
+ * Add upstream patch 04-cache-memory-leak, which fixes a memory leak when
+ using mlt_cache for frames.
+
+ -- Patrick Matthäi <pmatthaei at debian.org> Tue, 28 Aug 2012 20:31:07 +0200
+
mlt (0.8.0-3) unstable; urgency=low
* Disable compression from the luma module on mips. The convert process never
diff --git a/debian/patches/04-cache-memory-leak.diff b/debian/patches/04-cache-memory-leak.diff
new file mode 100644
index 0000000..d7c64a3
--- /dev/null
+++ b/debian/patches/04-cache-memory-leak.diff
@@ -0,0 +1,35 @@
+# Upstream patch to fix a memory leak when using mlt_cache for frames.
+
+diff -Naur mlt-0.8.0.orig/src/framework/mlt_cache.c mlt-0.8.0/src/framework/mlt_cache.c
+--- mlt-0.8.0.orig/src/framework/mlt_cache.c 2012-06-01 22:51:32.000000000 +0200
++++ mlt-0.8.0/src/framework/mlt_cache.c 2012-08-28 20:27:03.371711652 +0200
+@@ -83,6 +83,7 @@
+ {
+ int count; /**< the number of items currently in the cache */
+ int size; /**< the maximum number of items permitted in the cache <= \p MAX_CACHE_SIZE */
++ int is_frames; /**< indicates if this cache is used to cache frames */
+ void* *current; /**< pointer to the current array of pointers */
+ void* A[ MAX_CACHE_SIZE ];
+ void* B[ MAX_CACHE_SIZE ];
+@@ -122,6 +123,13 @@
+ {
+ char key[19];
+
++ if ( cache->is_frames )
++ {
++ // Frame caches are easy - just close the object as mlt_frame.
++ mlt_frame_close( object );
++ return;
++ }
++
+ // Fetch the cache item from the active list by its owner's address
+ sprintf( key, "%p", object );
+ mlt_cache_item item = mlt_properties_get_data( cache->active, key, NULL );
+@@ -554,6 +562,7 @@
+
+ // swap the current array
+ cache->current = (void**) alt;
++ cache->is_frames = 1;
+ pthread_mutex_unlock( &cache->mutex );
+ }
+
diff --git a/debian/patches/series b/debian/patches/series
index fc9974a..a498a74 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -1,3 +1,4 @@
01-changed-preset-path.diff
02-allow-file-prefix.diff
03-audio-limits-and-crash.diff
+04-cache-memory-leak.diff
--
MLT multimedia framework packaging
More information about the pkg-kde-commits
mailing list