php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #428 misappropriating values
Submitted: 1998-06-02 22:41 UTC Modified: 1998-06-03 09:04 UTC
Votes:1
Avg. Score:5.0 ± 0.0
Reproduced:0 of 1 (0.0%)
From: ccurtis at ee dot fit dot edu Assigned: rasmus (profile)
Status: Closed Package: Parser error
PHP Version: 3.0 Release Candidate 5 OS: Solaris 2.4
Private report: No CVE-ID: None
 [1998-06-02 22:41 UTC] ccurtis at ee dot fit dot edu
class MyClass
{  var $Database = 0, $Tree = 1;

   // Returns the previous selection or zero if tree is empty
   cFunction SetTree( $newtree )
   {  $rv = $this->$Tree;
      $this->$Tree = $newtree;
      return $rv;
   }
}

Before the call:
$Database = 1
$Tree = 1

Call: $this->SetTree( $tree ) where $tree = "test"

After the line:  $this->$Tree = $newtree
$Database = test
$Tree = 1

This one's more of a stickler.
Chris

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [1998-06-03 09:04 UTC] rasmus
Not a bug
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Fri Apr 26 09:01:29 2024 UTC