|  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #29847 bcsqrt crashes - problem reproducable
Submitted: 2004-08-26 12:52 UTC Modified: 2004-08-28 12:13 UTC
From: aliendesaster at hotmail dot com Assigned:
Status: Not a bug Package: BC math related
PHP Version: 5.0.1 OS: WinXP
Private report: No CVE-ID: None
 [2004-08-26 12:52 UTC] aliendesaster at hotmail dot com
It?s simple: bcsqrt doesn?t work at all, it?s always causing a crash unlike sqrt, which works! I dunno if bcsqrt working in other php version.

I?m installed the php 5.01 win-binary version (zip) from

Reproduce code:
echo bcsqrt('45.0');  //causes crash


echo bcsqrt(45.0);    //causes crash too


echo bcsqrt(45);    //always crashing, yeah

Expected result:
result should be similar to what sqrt(45) returns.

Actual result:
A nice reproducable crash in apache:
AppName: apache.exe	 AppVer:	 ModName: php5ts.dll
ModVer:	 Offset: 0008238f


Add a Patch

Pull Requests

Add a Pull Request


AllCommentsChangesGit/SVN commitsRelated reports
 [2004-08-27 00:54 UTC]
Please try using this CVS snapshot:
For Windows:

Seems to work fine with latest CVS, the result is  
6.70820393249936908922752100619382 for all 3 sample codes. 
 [2004-08-27 16:06 UTC] aliendesaster at hotmail dot com
True, since I only got 56k I usually don?t update that often but the latest CVS snapshot works. Might be closed then. Thanks for your help :)
 [2004-08-27 16:07 UTC] aliendesaster at hotmail dot com
well, I can close myself, do I? Let?s check...
 [2004-08-27 17:15 UTC]
Yes, but since this was actually a duplicate of a bug that was already fixed (which is why the snapsshot works for you) it should actually be marked 'Bogus'.  Nothing personal about you or the bug, just part of the statistical analysis.
 [2004-08-28 12:13 UTC] aliendesaster at hotmail dot com
Actually, I now know what caused the problem:
The problem was the file php5ts which I once copied to C:\windows\system32\
for some reason I don?t now heh. Well, this was really stupid. I wonder why bcsqrt() worked after I unzipped php5-dev snapshot till I switched apache 2 from *.47 to *.50 and restarted my computer.
However, It seems I worked with a pre-php distribution version all the time...damn. No wonder that this bug has been fixed could I notice that then;)
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Sun Jun 23 11:01:30 2024 UTC