diff options
author | Evan Prodromou <evan@status.net> | 2009-10-15 04:49:59 -0400 |
---|---|---|
committer | Evan Prodromou <evan@status.net> | 2009-10-15 04:49:59 -0400 |
commit | c1c8daa021db8629ceb46d52c3907b4844fe865e (patch) | |
tree | 3658949e3ff4a9df3232cb4fc36e55096f591c0a /extlib/php-gettext/gettext.php | |
parent | 2e3cda4da626a83d87a4c35814d6d01307dde5dc (diff) | |
parent | 6b5810f5d562260a0143446982bf22ef50298d80 (diff) |
Merge branch '0.9.x' of git@gitorious.org:statusnet/mainline into 0.9.x
Diffstat (limited to 'extlib/php-gettext/gettext.php')
-rw-r--r-- | extlib/php-gettext/gettext.php | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/extlib/php-gettext/gettext.php b/extlib/php-gettext/gettext.php index ad94a987b..cd080444c 100644 --- a/extlib/php-gettext/gettext.php +++ b/extlib/php-gettext/gettext.php @@ -102,16 +102,16 @@ class gettext_reader { // Caching can be turned off $this->enable_cache = $enable_cache; - // $MAGIC1 = (int)0x950412de; //bug in PHP 5 + // $MAGIC1 = (int)0x950412de; //bug in PHP 5.0.2, see https://savannah.nongnu.org/bugs/?func=detailitem&item_id=10565 $MAGIC1 = (int) - 1794895138; // $MAGIC2 = (int)0xde120495; //bug $MAGIC2 = (int) - 569244523; $this->STREAM = $Reader; $magic = $this->readint(); - if ($magic == $MAGIC1) { + if ($magic == ($MAGIC1 & 0xFFFFFFFF)) { // to make sure it works for 64-bit platforms $this->BYTEORDER = 0; - } elseif ($magic == $MAGIC2) { + } elseif ($magic == ($MAGIC2 & 0xFFFFFFFF)) { $this->BYTEORDER = 1; } else { $this->error = 1; // not MO file |