Escape special chars in regex. Props eightize and Otto42. fixes #4873

git-svn-id: http://svn.automattic.com/wordpress/trunk@5986 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
ryan 2007-08-30 15:42:26 +00:00
parent 88f73f7f41
commit 5a997f588b
1 changed files with 1 additions and 1 deletions

View File

@ -398,7 +398,7 @@ function wp_redirect($location, $status = 302) {
if ( !$location ) // allows the wp_redirect filter to cancel a redirect
return false;
$location = preg_replace('|[^a-z0-9-~+_.?#=&;,/:%]|i', '', $location);
$location = preg_replace('|[^a-z0-9-~\+_\.\?#=&;,/:%]|i', '', $location);
$location = wp_kses_no_null($location);
$strip = array('%0d', '%0a');