Add a prophylactic sanitize_user()

git-svn-id: http://svn.automattic.com/wordpress/trunk@5683 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
ryan 2007-06-12 18:11:06 +00:00
parent 66e6a55c7e
commit 21dff0640c
1 changed files with 2 additions and 0 deletions

View File

@ -304,6 +304,8 @@ if ( !function_exists('wp_login') ) :
function wp_login($username, $password, $already_md5 = false) { function wp_login($username, $password, $already_md5 = false) {
global $wpdb, $error; global $wpdb, $error;
$username = sanitize_user($username);
if ( '' == $username ) if ( '' == $username )
return false; return false;