[gtk-osx] Add bison patch fixing vasnprintf() under macOS 10.13
- From: John Ralls <jralls src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk-osx] Add bison patch fixing vasnprintf() under macOS 10.13
- Date: Fri, 29 Sep 2017 13:45:38 +0000 (UTC)
commit 545dc1c6839883d2f8a290d8719aa348556c51d5
Author: Jiří Techet <techet gmail com>
Date: Fri Sep 29 12:28:31 2017 +0200
Add bison patch fixing vasnprintf() under macOS 10.13
vasnprintf() now intentionally crashes on macOS 10.13 when the
formatting string contains %n and is dynamically allocated. Avoid
this by doing the same as in the Windows implementation.
modulesets-stable/bootstrap.modules | 4 +++-
patches/bison-3.0.4-vasnprintf.patch | 11 +++++++++++
2 files changed, 14 insertions(+), 1 deletions(-)
---
diff --git a/modulesets-stable/bootstrap.modules b/modulesets-stable/bootstrap.modules
index c49962e..f48ceee 100644
--- a/modulesets-stable/bootstrap.modules
+++ b/modulesets-stable/bootstrap.modules
@@ -143,7 +143,9 @@
requires 2.4. -->
<autotools id="bison" autogen-sh="configure">
<branch repo="ftp.gnu.org" module="bison/bison-3.0.4.tar.xz"
- version="3.0.4"/>
+ version="3.0.4">
+ <patch file="https://git.gnome.org/browse/gtk-osx/plain/patches/bison-3.0.4-vasnprintf.patch"
strip="1"/>
+ </branch>
<dependencies>
<dep package='flex'/>
</dependencies>
diff --git a/patches/bison-3.0.4-vasnprintf.patch b/patches/bison-3.0.4-vasnprintf.patch
new file mode 100644
index 0000000..adc1452
--- /dev/null
+++ b/patches/bison-3.0.4-vasnprintf.patch
@@ -0,0 +1,11 @@
+--- bison-3.0.4-orig/lib/vasnprintf.c 2017-09-29 11:10:29.000000000 +0200
++++ bison-3.0.4/lib/vasnprintf.c 2017-09-29 11:15:06.000000000 +0200
+@@ -4858,7 +4858,7 @@
+ #endif
+ *fbp = dp->conversion;
+ #if USE_SNPRINTF
+-# if !(((__GLIBC__ > 2 || (__GLIBC__ == 2 && __GLIBC_MINOR__ >= 3)) && !defined __UCLIBC__) || ((defined
_WIN32 || defined __WIN32__) && ! defined __CYGWIN__))
++# if !(((__GLIBC__ > 2 || (__GLIBC__ == 2 && __GLIBC_MINOR__ >= 3)) && !defined __UCLIBC__) || ((defined
_WIN32 || defined __WIN32__) && ! defined __CYGWIN__) || defined __APPLE__)
+ fbp[1] = '%';
+ fbp[2] = 'n';
+ fbp[3] = '\0';
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]