How do I verify a
This release includes a fix for potential security issue allowing code injection into the ngettext family of calls: evaluating the plural form formula can execute arbitrary code if number is passed unsanitized from the untrusted user. php-gettext will now throw an exception if the value being passed in is not a number, thus supporting good programming practices: always validate user input at the point of "entry".
Long-committed but never released fix for bug 734494 is also included.
Security fix for potential code injection bug (#1515334).
Do not assume mbstring functions are always there, pass text through if they aren't (#734494).
Fixes a few problems in emulation functions for gettext interfaces.
Includes fixes for several bugs included deprecation warnings and non-strict error messages, new unit tests for small bits of code, and experimental pgettext support.
This release incorporates a few E_STRICT fixes, improved plural form expression parsing (making it more compatible with standard GNU gettext behaviour), and better locale fallbacks (again, making them more compatible with standard gettext).
Fix a long standing endianness detection through magic number bug, frequently broken with PHP bugs.
2006-02-07 Danilo Šegan <email address hidden>
* examples/pigs_dropin.php: comment-out bind_textdomain_codeset
* gettext.inc (T_bind_textdomain_codeset): bind_textdomain_codeset
is available only in PHP 4.2.0+ (thanks to Jens A. Tkotz).
* Makefile: Include gettext.inc in DIST_FILES, VERSION up to
2006-02-03 Danilo Šegan <email address hidden>
Added setlocale() emulation as well.
* examples/pigs_dropin.php: Use T_setlocale() and locale_emulation().
* examples/pigs_fallback.php: Use T_setlocale() and locale_emulation().
* gettext.inc: Added globals $EMULATEGETTEXT and $CURRENTLOCALE.
(locale_emulation): Whether emulation is active.
(_setlocale): Added emulated setlocale function.
(T_setlocale): Wrapper around _setlocale.
(_get_reader): Use variables and _setlocale.
2006-02-02 Danilo Šegan <email address hidden>
Fix bug #12192.
* examples/locale/sr_CS/LC_MESSAGES/messages.po: Correct grammar.
* examples/locale/sr_CS/LC_MESSAGES/messages.mo: Rebuild.
Fix bug #15419.
* streams.php: Support for PHP 5.1.1 fread() which reads most 8kb.
(Thanks to Shot on Savannah)
Merge Steven Armstrong's changes, supporting standard gettext
* examples/*: Restructured examples.
* gettext.inc: Added.
* AUTHORS: Added Steven.
* Makefile (VERSION): Up to 1.0.6.
2006-01-28 Nico Kaiser <email address hidden>
* gettext.php (select_string): Fix "true" <-> 1 difference of PHP
2005-07-29 Danilo Šegan <email address hidden>
* Makefile (VERSION): Up to 1.0.5.
Fixes bug #13850.
* gettext.php (gettext_reader): check $Reader->error as well.
* Makefile (VERSION): Up to 1.0.4.
Fixes bug #13771.
* gettext.php (gettext_reader->get_plural_forms): Plural forms
header extraction regex change. Reported by Edgar Gonzales.
2005-02-28 Danilo Šegan <email address hidden>
* AUTHORS: Added Nico to the list.
* Makefile (VERSION): Up to 1.0.3.
* README: Updated.
* gettext.php: Added pre-loading, code documentation, and many
code clean-ups by Nico Kaiser <email address hidden>.
* streams.php (FileReader.read): Handle read($bytes = 0).
* examples/pigs.php: Prefix gettext function names with T or T_.
* examples/update: Use the same keywords T_ and T_ngettext.
* streams.php: Added CachedFileReader.
2003-11-11 Danilo Šegan <email address hidden>
* gettext.php: Added hashing to find_string.