Join GitHub today
GitHub is home to over 31 million developers working together to host and review code, manage projects, and build software together.Sign up
Running msgfmt to build Java2 resources crashes with specific string lengths of msgctxt and msgid #38808
Please note we will close your issue without comment if you delete, do not read or do not fill out the issue checklist below and provide ALL the requested information. If you repeatedly fail to use the issue template, we will block you from ever submitting issues to Homebrew again.
To help us debug your issue please explain:
The problem seems to be related to the combined string lenghts of the
For example, the following values crash msgfmt, too (
msgctxt "four" msgid "sixplusfive" msgctxt "context" msgid "can hurt"
It looks like if the sum of both values’ lengths equals 15, msgfmt is going to crash – slightly modified values prevent the crash and create the Java message file accordingly:
msgctxt "123456789x" msgid "abcdef" msgctxt "123456789" msgid "abcdef_" msgctxt "four" msgid "six-plus-five" msgctxt "context" msgid "is hard"
What could cause this behaviour? And how could it sneak into the macos binary only – not in the Linux one (assuming the same source code is used for both platforms)?
The issue could be verified on two different macos installations, one of them with the following specs:
# sw_vers ProductName: Mac OS X ProductVersion: 10.14.3 BuildVersion: 18D109 # msgfmt -V msgfmt (GNU gettext-tools) 0.19.8.1 Copyright (C) 1995-1998, 2000-2016 Free Software Foundation, Inc. License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html> This is free software: you are free to change and redistribute it. There is NO WARRANTY, to the extent permitted by law. Written by Ulrich Drepper. # brew -v Homebrew 2.1.0 Homebrew/homebrew-core (git revision 4ab838; last commit 2019-04-09) Homebrew/homebrew-cask (git revision 5371d; last commit 2019-04-10)
Please let me know if additional information is required.