Add patch to fix build on some archs.
authorJaromír Mikeš <mira.mikes@seznam.cz>
Wed, 17 Jan 2018 17:45:42 +0000 (18:45 +0100)
committerJaromír Mikeš <mira.mikes@seznam.cz>
Wed, 17 Jan 2018 17:45:42 +0000 (18:45 +0100)
debian/patches/05-fix_FTBS_on_some_archs.patch [new file with mode: 0644]
debian/patches/series

diff --git a/debian/patches/05-fix_FTBS_on_some_archs.patch b/debian/patches/05-fix_FTBS_on_some_archs.patch
new file mode 100644 (file)
index 0000000..bf2e12c
--- /dev/null
@@ -0,0 +1,20 @@
+Description: Fix FTBFS on some archs.
+Author: James Cowgill <jcowgill@debian.org>
+jcowgill@debian.org
+Forwarded: no
+
+Index: giada/src/utils/string.cpp
+===================================================================
+--- giada.orig/src/utils/string.cpp
++++ giada/src/utils/string.cpp
+@@ -108,7 +108,9 @@ std::string gu_format(const char* format
+       /* Compute the size of the new expanded string (i.e. with replacement taken
+       into account). */
+-      size_t size = vsnprintf(nullptr, 0, format, args);
++  va_start(args, format);
++      size_t size = vsnprintf(nullptr, 0, format, args) + 1;
++  va_end(args);
+       /* Create a new temporary char array to hold the new expanded string. */
index a09bfd02b2858bccf4f8054eb918515b8233d351..4560b8d92b5337a520d66564ec9c740d384293a7 100644 (file)
@@ -1,3 +1,4 @@
 01-rtaudio5.patch
 02-rtmidi-pkgconfig.patch
 04-catch.patch
+05-fix_FTBS_on_some_archs.patch