[SCM] flac/master: Import two patches from upstream GIT.
fabian-guest at users.alioth.debian.org
fabian-guest at users.alioth.debian.org
Thu Jun 6 10:31:17 UTC 2013
The following commit has been merged in the master branch:
commit 71dbb2d3b1c2b6863bd4295a70b382d520b34fb4
Author: Fabian Greffrath <fabian at greffrath.com>
Date: Thu Jun 6 12:28:37 2013 +0200
Import two patches from upstream GIT.
diff --git a/debian/patches/0002-Add-missing-config.h-includes.patch b/debian/patches/0002-Add-missing-config.h-includes.patch
new file mode 100644
index 0000000..06bf31a
--- /dev/null
+++ b/debian/patches/0002-Add-missing-config.h-includes.patch
@@ -0,0 +1,221 @@
+From d42c04260bf9e27cbb8c61a5529ecab3b20e25ff Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?Cristian=20Rodr=C3=ADguez?= <crrodriguez at opensuse.org>
+Date: Fri, 31 May 2013 21:55:55 -0400
+Subject: [PATCH 2/3] Add missing config.h includes
+
+All C and C++ files must include config.h
+
+Signed-off-by: Erik de Castro Lopo <erikd at mega-nerd.com>
+---
+ src/libFLAC++/metadata.cpp | 4 ++++
+ src/libFLAC++/stream_decoder.cpp | 4 ++++
+ src/libFLAC++/stream_encoder.cpp | 4 ++++
+ src/plugin_xmms/charset.c | 4 ++++
+ src/plugin_xmms/configure.c | 4 ++++
+ src/plugin_xmms/fileinfo.c | 4 ++++
+ src/plugin_xmms/http.c | 4 ++++
+ src/plugin_xmms/plugin.c | 4 ++++
+ src/plugin_xmms/tag.c | 4 ++++
+ src/share/grabbag/alloc.c | 4 ++++
+ src/test_libFLAC++/encoders.cpp | 4 ++++
+ src/test_libFLAC++/main.cpp | 4 ++++
+ src/test_libFLAC++/metadata.cpp | 4 ++++
+ src/test_libFLAC++/metadata_object.cpp | 4 ++++
+ src/utils/flactimer/main.cpp | 4 ++++
+ 15 files changed, 60 insertions(+)
+
+--- a/src/libFLAC++/metadata.cpp
++++ b/src/libFLAC++/metadata.cpp
+@@ -31,6 +31,10 @@
+ */
+
+ #define __STDC_LIMIT_MACROS 1 /* otherwise SIZE_MAX is not defined for c++ */
++#ifdef HAVE_CONFIG_H
++#include "config.h"
++#endif
++
+ #include "share/alloc.h"
+ #include "FLAC++/metadata.h"
+ #include "FLAC/assert.h"
+--- a/src/libFLAC++/stream_decoder.cpp
++++ b/src/libFLAC++/stream_decoder.cpp
+@@ -30,6 +30,10 @@
+ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
++#ifdef HAVE_CONFIG_H
++#include "config.h"
++#endif
++
+ #include "FLAC++/decoder.h"
+ #include "FLAC/assert.h"
+
+--- a/src/libFLAC++/stream_encoder.cpp
++++ b/src/libFLAC++/stream_encoder.cpp
+@@ -30,6 +30,10 @@
+ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
++#ifdef HAVE_CONFIG_H
++#include "config.h"
++#endif
++
+ #include "FLAC++/encoder.h"
+ #include "FLAC++/metadata.h"
+ #include "FLAC/assert.h"
+--- a/src/plugin_xmms/charset.c
++++ b/src/plugin_xmms/charset.c
+@@ -20,6 +20,10 @@
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
+ */
+
++#ifdef HAVE_CONFIG_H
++#include "config.h"
++#endif
++
+ #include "plugin.h"
+
+ #include <stdlib.h>
+--- a/src/plugin_xmms/configure.c
++++ b/src/plugin_xmms/configure.c
+@@ -21,6 +21,10 @@
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
+ */
+
++#ifdef HAVE_CONFIG_H
++#include "config.h"
++#endif
++
+ #include "plugin.h"
+
+ #include <stdlib.h>
+--- a/src/plugin_xmms/fileinfo.c
++++ b/src/plugin_xmms/fileinfo.c
+@@ -18,6 +18,10 @@
+ * with this program; if not, write to the Free Software Foundation, Inc.,
+ */
+
++#ifdef HAVE_CONFIG_H
++#include "config.h"
++#endif
++
+ #include "plugin.h"
+
+ #include <stdlib.h>
+--- a/src/plugin_xmms/http.c
++++ b/src/plugin_xmms/http.c
+@@ -17,6 +17,10 @@
+ */
+ /* modified for FLAC support by Steven Richman (2003) */
+
++#ifdef HAVE_CONFIG_H
++#include "config.h"
++#endif
++
+ #include "plugin.h"
+
+ #include <sys/types.h>
+--- a/src/plugin_xmms/plugin.c
++++ b/src/plugin_xmms/plugin.c
+@@ -17,6 +17,10 @@
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
+ */
+
++#ifdef HAVE_CONFIG_H
++#include "config.h"
++#endif
++
+ #include "plugin.h"
+
+ #include <limits.h>
+--- a/src/plugin_xmms/tag.c
++++ b/src/plugin_xmms/tag.c
+@@ -20,6 +20,10 @@
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
+ */
+
++#ifdef HAVE_CONFIG_H
++#include "config.h"
++#endif
++
+ #include "plugin.h"
+
+ #include <stdlib.h>
+--- a/src/share/grabbag/alloc.c
++++ b/src/share/grabbag/alloc.c
+@@ -30,6 +30,10 @@
+ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
++#ifdef HAVE_CONFIG_H
++#include "config.h"
++#endif
++
+ #include <stdlib.h>
+
+ #include "share/alloc.h"
+--- a/src/test_libFLAC++/encoders.cpp
++++ b/src/test_libFLAC++/encoders.cpp
+@@ -17,6 +17,10 @@
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
+ */
+
++#ifdef HAVE_CONFIG_H
++#include "config.h"
++#endif
++
+ #include "encoders.h"
+ #include "FLAC/assert.h"
+ #include "FLAC++/encoder.h"
+--- a/src/test_libFLAC++/main.cpp
++++ b/src/test_libFLAC++/main.cpp
+@@ -17,6 +17,10 @@
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
+ */
+
++#ifdef HAVE_CONFIG_H
++#include "config.h"
++#endif
++
+ #include "decoders.h"
+ #include "encoders.h"
+ #include "metadata.h"
+--- a/src/test_libFLAC++/metadata.cpp
++++ b/src/test_libFLAC++/metadata.cpp
+@@ -17,6 +17,10 @@
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
+ */
+
++#ifdef HAVE_CONFIG_H
++#include "config.h"
++#endif
++
+ #include "metadata.h"
+ #include <stdio.h>
+
+--- a/src/test_libFLAC++/metadata_object.cpp
++++ b/src/test_libFLAC++/metadata_object.cpp
+@@ -17,6 +17,10 @@
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
+ */
+
++#ifdef HAVE_CONFIG_H
++#include "config.h"
++#endif
++
+ #include <stdio.h>
+ #include <stdlib.h> /* for malloc() */
+ #include <string.h> /* for memcmp() */
+--- a/src/utils/flactimer/main.cpp
++++ b/src/utils/flactimer/main.cpp
+@@ -17,6 +17,10 @@
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
+ */
+
++#ifdef HAVE_CONFIG_H
++#include "config.h"
++#endif
++
+ #include <stdio.h>
+ #include <string.h>
+ #include <windows.h>
diff --git a/debian/patches/0003-metaflac-Fix-local_strcat-to-terminate-string-correc.patch b/debian/patches/0003-metaflac-Fix-local_strcat-to-terminate-string-correc.patch
new file mode 100644
index 0000000..b4c207a
--- /dev/null
+++ b/debian/patches/0003-metaflac-Fix-local_strcat-to-terminate-string-correc.patch
@@ -0,0 +1,26 @@
+From 606fdfcaece19d3e05434bde57c289102a369069 Mon Sep 17 00:00:00 2001
+From: Miroslav Lichvar <mlichvar at redhat.com>
+Date: Mon, 3 Jun 2013 13:09:05 +0200
+Subject: [PATCH 3/3] metaflac : Fix local_strcat() to terminate string
+ correctly.
+
+The NUL char is written at incorrect place when the destination string
+is longer than 0, which causes memory corruption. It was broken by
+commit 2d6354ff2a618a79d40edbd4f208b4b07c5422f1.
+
+Signed-off-by: Erik de Castro Lopo <erikd at mega-nerd.com>
+---
+ src/metaflac/utils.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+--- a/src/metaflac/utils.c
++++ b/src/metaflac/utils.c
+@@ -75,7 +75,7 @@ void local_strcat(char **dest, const cha
+ *dest = safe_realloc_add_3op_(*dest, ndest, /*+*/nsource, /*+*/1);
+ if(0 == *dest)
+ die("out of memory growing string");
+- safe_strncpy((*dest)+ndest, source, ndest + nsource + 1);
++ safe_strncpy((*dest)+ndest, source, nsource + 1);
+ }
+
+ static inline int local_isprint(int c)
diff --git a/debian/patches/series b/debian/patches/series
index 17e97af..f168c1c 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -1 +1,3 @@
Revert-man-Makefile-Fail-more-gracefully.patch
+0002-Add-missing-config.h-includes.patch
+0003-metaflac-Fix-local_strcat-to-terminate-string-correc.patch
--
flac packaging
More information about the pkg-multimedia-commits
mailing list