php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #5633 crash on return value of a function (5582 updated seems to be an array pb)
Submitted: 2000-07-17 05:29 UTC Modified: 2000-10-02 22:50 UTC
From: administrateur at micro-assist dot fr Assigned:
Status: Closed Package: MSSQL related
PHP Version: 4.0 Latest CVS (17/07/2000) OS: win2000
Private report: No CVE-ID: None
 [2000-07-17 05:29 UTC] administrateur at micro-assist dot fr
Update of bug 5582
Seems to  be arrays problem !
It happens on the return of a function !?
Better crash with reurn of NULL values ?

An exemple for the good crash:

function toto() {
global $r;
$dd=mssql_fetch_array($r);
$dd["titi"]=$dd["riri"]+1;
$dd[0]=(($sens!=0)?"na":$dd[0]);
return $dd;
}
.....
connect to a db mssql_connect .....
.....
$qr="SELECT SUM(field2) AS field2 FROM table1";
$r=mssql_query($qr,$iddb);
for ($i=0;$i<30;$i++) {
$dd1=toto();
$dd0=toto(); //CRASH HERE .............
var_dump($dd1);
}
echo "ok";


Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2000-08-06 18:57 UTC] stas@php.net
reclassify
 [2000-09-04 20:40 UTC] sniper@php.net
Is this still happening with php4.0.2 (or latest CVS) ??

--Jani
 [2000-10-02 22:50 UTC] sniper@php.net
No feedback.

--Jani
 
PHP Copyright © 2001-2021 The PHP Group
All rights reserved.
Last updated: Tue Dec 07 12:03:34 2021 UTC