#40576 [NEW]: long values are truncated to 6 decimal digits upon encoding
| From: | giunta dot gaetano at sea-aeroportimilano dot it | Date: | Wed, 21 Feb 2007 11:46:29 +0000 |
| Subject: | #40576 [NEW]: long values are truncated to 6 decimal digits upon encoding | ||
| Groups: | php.bugs | ||
| Request: | Send a blank email to php-bugs+get-109246@lists.php.net to get a copy of this message | ||
From: giunta dot gaetano at sea-aeroportimilano dot it
Operating system: win2k sp4
PHP version: 5.2.1
PHP Bug Type: XMLRPC-EPI related
Bug description: long values are truncated to 6 decimal digits upon encoding
Description:
------------
As per the subject.
Please note I am fully aware it is the fault of the underlying EPI lib,
plus the xmlrpc spec does not mandate a strict number of digits as
min/max.
BUT
- the epi lib is dead for all purposes but php. Hacking it might be
advisable
- 6 digits is a very, very low figure...
Thanks
Gaetano
Reproduce code:
---------------
<?php
echo htmlspecialchars(xmlrpc_encode(1.123456789));
?>
Expected result:
----------------
<?xml version="1.0" encoding="utf-8"?> <params> <param>
<value>
<double>1.123457</double> </value> </param> </params>
Actual result:
--------------
<?xml version="1.0" encoding="utf-8"?> <params> <param>
<value>
<double>1.123456789</double> </value> </param> </params>
--
Edit bug report at http://bugs.php.net/?id=40576&edit=1
--
Try a CVS snapshot (PHP 4.4): http://bugs.php.net/fix.php?id=40576&r=trysnapshot44
Try a CVS snapshot (PHP 5.2): http://bugs.php.net/fix.php?id=40576&r=trysnapshot52
Try a CVS snapshot (PHP 6.0): http://bugs.php.net/fix.php?id=40576&r=trysnapshot60
Fixed in CVS: http://bugs.php.net/fix.php?id=40576&r=fixedcvs
Fixed in release: http://bugs.php.net/fix.php?id=40576&r=alreadyfixed
Need backtrace: http://bugs.php.net/fix.php?id=40576&r=needtrace
Need Reproduce Script: http://bugs.php.net/fix.php?id=40576&r=needscript
Try newer version: http://bugs.php.net/fix.php?id=40576&r=oldversion
Not developer issue: http://bugs.php.net/fix.php?id=40576&r=support
Expected behavior: http://bugs.php.net/fix.php?id=40576&r=notwrong
Not enough info: http://bugs.php.net/fix.php?id=40576&r=notenoughinfo
Submitted twice: http://bugs.php.net/fix.php?id=40576&r=submittedtwice
register_globals: http://bugs.php.net/fix.php?id=40576&r=globals
PHP 3 support discontinued: http://bugs.php.net/fix.php?id=40576&r=php3
Daylight Savings: http://bugs.php.net/fix.php?id=40576&r=dst
IIS Stability: http://bugs.php.net/fix.php?id=40576&r=isapi
Install GNU Sed: http://bugs.php.net/fix.php?id=40576&r=gnused
Floating point limitations: http://bugs.php.net/fix.php?id=40576&r=float
No Zend Extensions: http://bugs.php.net/fix.php?id=40576&r=nozend
MySQL Configuration Error: http://bugs.php.net/fix.php?id=40576&r=mysqlcfg