#44912 [Com]: Can not output float data correctly on PowerPC

[email protected] ("julia dot keffer at pikatech dot com")
Newsgroups php.bugs
Message-ID <[email protected]>
 ID:               44912
 Comment by:       julia dot keffer at pikatech dot com
 Reported By:      zhy_cqit at 163 dot com
 Status:           Open
 Bug Type:         BC math related
 Operating System: Linux Kernel 2.6.20
 PHP Version:      5.2.6
 New Comment:

I had the same problem with version 5.2.5 when trying to cross compile
for the PowerPC. The comments in these two bug reports gave me a
solution:

http://bugs.php.net/bug.php?id=41951
- I changed the values of the variables mentioned to 4
http://bugs.php.net/bug.php?id=45148
- I forced ac_cv_c_bigendian_php=yes as suggested


Previous Comments:
------------------------------------------------------------------------

[2008-05-05 06:43:14] zhy_cqit at 163 dot com

Description:
------------
The PHP5 has been cross compiled and let it running on the PowerPC. 
While executing a division and the result is a float data, it will
output a wrong number or crashed!

Reproduce code:
---------------
<?php

   $percent = 5/2;

   echo $percent;

?>


Expected result:
----------------
2.5

Actual result:
--------------
PHP Fatal error:  Balloc() allocation exceeds list boundary in
/mnt/apache2/htdocs/test.php on line 3

Fatal error: Balloc() allocation exceeds list boundary in
/mnt/apache2/htdocs/test.php on line 3



------------------------------------------------------------------------


-- 
Edit this bug report at http://bugs.php.net/?id=44912&edit=1
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.