Zend Framework

The Zend Tool zf.php script uses $_ENV instead of getenv(), in recent releases of php, the $_ENV superglobal is not populated in the recommended php.ini file

Details

  • Type: Bug Bug
  • Status: Resolved Resolved
  • Priority: Major Major
  • Resolution: Fixed
  • Affects Version/s: 1.9.0
  • Fix Version/s: 1.9.1
  • Component/s: Zend_Tool
  • Labels:
    None

Description

Recent versions of the distributed/recommended php.ini file state that the superglobal variable order should be "GPCS" (i.e. variables_order = "GPCS"). Since E is omitted, the $_ENV superglobal is never populated and the ini file recommends always using getwnv() in preference to $_ENV.

The Zend Tool zf.php file uses $_ENV and getenv() erratically, sometimes checking for the existence of an environment var with getenv() and then assuming it's existence by referencing the $_ENV array. All references in this file should use getenv().

Activity

Hide
Peter Chapman added a comment -

I have attached the file with $_ENV factored out in favor of getenv()

Show
Peter Chapman added a comment - I have attached the file with $_ENV factored out in favor of getenv()
Hide
Ralph Schindler added a comment -

Fixed in trunk in r17522 and 1.9 release branch in r17524

Show
Ralph Schindler added a comment - Fixed in trunk in r17522 and 1.9 release branch in r17524
Hide
Ralph Schindler added a comment -

Updating fix information

Show
Ralph Schindler added a comment - Updating fix information

People

Vote (0)
Watch (0)

Dates

  • Created:
    Updated:
    Resolved: