Fwd: [BULK] [PECL-BUG] Bug #17099 [NEW]: Date read from amf as double not int64
| From: | Emanuele Ruffaldi | Date: | Wed, 10 Mar 2010 18:37:50 +0000 |
| Subject: | Fwd: [BULK] [PECL-BUG] Bug #17099 [NEW]: Date read from amf as double not int64 | ||
| Groups: | php.pecl.dev | ||
| Request: | Send a blank email to pecl-dev+get-7074@lists.php.net to get a copy of this message | ||
Dear All,
Joey Parrish will continue (resume) the workon amfext in conjunction with the recent revival
of amfphp Ariel Sommeria.
I will try to help him in case of need.
Thanks and
Best Regards,
Emanuele Ruffaldi
-------- Original Message --------
Subject: [BULK] [PECL-BUG] Bug #17099 [NEW]: Date read from amf as double not int64
Date: 10 Mar 2010 15:53:54 -0000
From: ssufficool at gmail dot com <pecl-dev@lists.php.net>
To: pit@sssup.it
From: ssufficool at gmail dot comOperating system: Ubuntu Linux 9.10 Package version: 0.9.2
PHP version: Irrelevant Package: amfext Bug Type: BugBug description: Date read from amf as double not int64 Description: ------------ teh serialized date is read from an AMF stream as a double and then re-ordered as big endian instead of being read as an int64 per the spec. The double is unusable in PHP as a date anyhow. Reproduce code: --------------- $amf = amf_decode($amfstream); echo $amf['date']; Expected result: ---------------- An integer or double value that is usable in PHP Actual result: -------------- 3.123456789E-306 --- SOLUTION? --- For PHP5.x read the int64, convert from milliseconds to seconds and return as ZVAL_LONG with a big fat note of the precision loss. -- Edit bug report at http://pecl.php.net/bugs/bug.php?id=17099&edit=1 --