php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Request #8172 allow extract() of numerically indexed arrays with EXTR_PREFIX_ALL
Submitted: 2000-12-08 11:25 UTC Modified: 2001-01-23 12:25 UTC
From: cynic at mail dot cz Assigned:
Status: Closed Package: Feature/Change Request
PHP Version: 4.0 Latest CVS (08/12/2000) OS: *
Private report: No CVE-ID: None
 [2000-12-08 11:25 UTC] cynic at mail dot cz
see subject. 

I don't know C, so I can't write it myself, but I think the 

if (zend_hash_get_current_key(Z_ARRVAL_PP(var_array), &varname, &lkey) == HASH_KEY_IS_STRING) {
	if (_valid_var_name(varname)) {

block of the extract function could be probably changed to 
1) check whether EXTR_PREFIX_ALL is set, 
2) if so, check, whether the PREFIXED varname is valid 

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2001-01-23 12:25 UTC] cynic@php.net
implemented.
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Fri Jun 28 09:01:28 2024 UTC