]> git.ipfire.org Git - thirdparty/gettext.git/commit
xgettext: Avoid a crash due to a python-brace-format string with a NUL byte.
authorBruno Haible <bruno@clisp.org>
Sun, 12 Mar 2023 10:45:11 +0000 (11:45 +0100)
committerBruno Haible <bruno@clisp.org>
Tue, 14 Mar 2023 01:57:28 +0000 (02:57 +0100)
commita03afb970c6abea8ac22b16df3cfc3419fdc795f
tree9ad765b97e5882350cc6b9115316f962e5487de4
parent589731cc1b49bfbb2467b102fba8e1afd2277eef
xgettext: Avoid a crash due to a python-brace-format string with a NUL byte.

* gettext-tools/src/format-python-brace.c: Improve comments.
(parse_directive): Don't read past the string end if c1 is NUL.
* gettext-tools/tests/xgettext-python-6: New file.
* gettext-tools/tests/Makefile.am (TESTS): Add it.
gettext-tools/src/format-python-brace.c
gettext-tools/tests/Makefile.am
gettext-tools/tests/xgettext-python-6 [new file with mode: 0755]