Re: [gtk-osx-users] vasnprintf() crash on macOS 10.13



Hi John,

bison has been updated in the maintenance branch

http://lists.gnu.org/archive/html/bug-bison/2017-09/msg00002.html

but the question is when a new release will be made. I've created the attached patch which fixes the problem for now. I hope I used the right path in the modulesets file - this is something I cannot test before it's committed.

Jiri


On Sat, Sep 16, 2017 at 9:37 PM, Jiří Techet <techet gmail com> wrote:
Hi John,

I've just reported the issue against bison. I've tried to rebuild everything from scratch with only bison patched and it seems to be the only problem I run into with Geany - the other uses don't seem to cause problems at least for me.

Anyway, I'm afraid that at least a temporary patch will be needed in gtk-osx.

Jiri

On Sat, Sep 16, 2017 at 5:34 PM, John Ralls <jralls ceridwen us> wrote:


On Sep 16, 2017, at 7:33 AM, Jiří Techet <techet gmail com> wrote:

Hi,

the vasnprintf() now intentionally crashes on macOS 10.13 when the formatting string contains %n and is dynamically allocated, for more, see


This problem affects all users of gnulib's vasnprintf implementation which are at least the following (found by find . -name "vasnprintf.c" in sources which I use for compiling Geany - but there may be more):

./pkg-config-0.29.2/glib/glib/gnulib/vasnprintf.c
./bison-3.0.4/lib/vasnprintf.c
./gettext-0.19.8/gettext-tools/libgettextpo/vasnprintf.c
./gettext-0.19.8/gettext-tools/gnulib-lib/vasnprintf.c
./gettext-0.19.8/gettext-runtime/intl/vasnprintf.c
./gettext-0.19.8/gettext-runtime/libasprintf/vasnprintf.c
./glib-2.52.2/glib/gnulib/vasnprintf.c

Without any change I get the first error when compiling bison:

  CCLD     src/bison
  GEN      doc/bison.help
/bin/sh: line 1: 77605 Illegal instruction: 4  src/bison --version > doc/bison.help.tmp
make[2]: *** [doc/bison.help] Error 132
make[1]: *** [all-recursive] Error 1
make: *** [all] Error 2
*** Error during phase build of bison: ########## Error running make -j 9  *** [17/24]

All of the above files should probably be patched - all of them already contain a fix for the same issue under Windows which behaves the same way - I just simply tried to add a simple condition "|| defined __APPLE__" to the place where this is tested and the Windows code seems to work fine. See the above gnulib mailing list link for more info.

Jiri,

Thanks for reporting that. I hope that the various upstreams get their gnu lib copies updated soon. Have you checked that bugs are filed with each of the upstreams?

Regards,
John Ralls




Attachment: 0001-Add-bison-patch-fixing-vasnprintf-under-macOS-10.13.patch
Description: Binary data



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]