Merge branch 'phpng' of git.php.net:php-src into phpng

# By Xinchen Hui
# Via Xinchen Hui
* 'phpng' of git.php.net:php-src:
  Save one type checking if the type is already string
  This should be removed too
  Remove zval **
hash keys now use actual string length without leading zero
ptr needed here
fix windows build
Merge branch 'phpng' of git.php.net:php-src into phpng

# By Stanislav Malyshev (15) and others
# Via Stanislav Malyshev (15) and others
* 'phpng' of git.php.net:php-src: (53 commits)
  Use defined macro
  Refactored tidy (all tests passes)
  Reverted wrong commit Xinchen, stop commit changed configs :) You may use environment variables to ovverride default settings
  Fixed reference counting, IS_REFERENCE and IS_INDIRECT support
  Terminate string Useproper hash function
  C89 compat
  Fixed curl_close() behavior
  In most user extensions functions like mysql_close() should use zend_list_close() instead of zend_list_delete(). This closes the actual connection and frees extension specific data structures, but doesn't free zend_reference structure that might be referenced from zval(s). This also doesn't decrement the resource reference counter.
  Fixed access to uninitialized data and attempt to double free
  Fixed safe resource close. It must not de deleted (just closed), because it still may be referenced from zval(s). This fixes few ext/ftp test memory failures detected with valgrind.
  Nested PCRE calls may clobber extra->mark and it has to be reinitailized This fixes invalid memory writes (detected with valgrind) in Zend/tests/closure_047.phpt and Zend/tests/closure_048.phpt.
  Added comment
  fix test - output can be chunked
  fix test
  fix test
  Fixed test for commit 997be125eb0228c5b1b6dd278f617791e71192c6
  Add bug fix to NEWS
  Update UPGRADING according to bug fix
  fix test
  improve CURL tests to allow testing without separate server
  ...