Go to:
Gentoo Home
Documentation
Forums
Lists
Bugs
Planet
Store
Wiki
Get Gentoo!
Gentoo's Bugzilla – Attachment 373760 Details for
Bug 482340
net-nds/phpldapadmin - broken with php-5.5
Home
|
New
–
[Ex]
|
Browse
|
Search
|
Privacy Policy
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
fix warning about preg_replace /e switch
phpldapadmin-1.2.3-fix-preg_replace_callback-notice.patch (text/plain), 1.38 KB, created by
Christohper Harrington
on 2014-03-28 17:30:06 UTC
(
hide
)
Description:
fix warning about preg_replace /e switch
Filename:
MIME Type:
Creator:
Christohper Harrington
Created:
2014-03-28 17:30:06 UTC
Size:
1.38 KB
patch
obsolete
>--- a/lib/functions.php >+++ b/lib/functions.php >@@ -2564,13 +2564,24 @@ > if (is_array($dn)) { > $a = array(); > >- foreach ($dn as $key => $rdn) >- $a[$key] = preg_replace('/\\\([0-9A-Fa-f]{2})/e',"''.chr(hexdec('\\1')).''",$rdn); >+ foreach ($dn as $key => $rdn) { >+ $a[$key] = preg_replace_callback('/\\\([0-9A-Fa-f]{2})/', >+ function ($m) { >+ return ''.chr(hexdec('\\1')).''; >+ }, >+ $rdn >+ ); >+ } > > return $a; > > } else { >- return preg_replace('/\\\([0-9A-Fa-f]{2})/e',"''.chr(hexdec('\\1')).''",$dn); >+ return preg_replace_callback('/\\\([0-9A-Fa-f]{2})/', >+ function ($m) { >+ return ''.chr(hexdec('\\1')).''; >+ }, >+ $dn >+ ); > } > } > > > >--- a/lib/ds_ldap.php >+++ b/lib/ds_ldap.php >@@ -1116,13 +1116,24 @@ > > if (is_array($dn)) { > $a = array(); >- foreach ($dn as $key => $rdn) >- $a[$key] = preg_replace('/\\\([0-9A-Fa-f]{2})/e',"''.chr(hexdec('\\1')).''",$rdn); >+ foreach ($dn as $key => $rdn) { >+ $a[$key] = preg_replace_callback('/\\\([0-9A-Fa-f]{2})/', >+ function ($m) { >+ return ''.chr(hexdec('\\1')).''; >+ }, >+ $rdn >+ ); >+ } > > return $a; > > } else >- return preg_replace('/\\\([0-9A-Fa-f]{2})/e',"''.chr(hexdec('\\1')).''",$dn); >+ return preg_replace_callback('/\\\([0-9A-Fa-f]{2})/', >+ function ($m) { >+ return ''.chr(hexdec('\\1')).''; >+ }, >+ $dn >+ ); > } > > public function getRootDSE($method=null) {
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 482340
:
357568
|
370938
|
370940
|
373756
|
373758
| 373760 |
373762
|
373766