diff options
| author | Andreas Fischer <bantu@phpbb.com> | 2011-06-12 19:24:00 +0200 |
|---|---|---|
| committer | Andreas Fischer <bantu@phpbb.com> | 2011-06-12 19:24:00 +0200 |
| commit | 4adfa4685096f05e989ba7168bfaa4146e0d7cb4 (patch) | |
| tree | 6214747ede2c140fe2df1612cd297f209ac4843e /phpBB/includes/auth/auth_db.php | |
| parent | bf2125f0f7c2b3d2f270ae4f3117941dd108f35a (diff) | |
| parent | 4e0717b4d7da58469c795191236ad4256a20c72a (diff) | |
| download | forums-4adfa4685096f05e989ba7168bfaa4146e0d7cb4.tar forums-4adfa4685096f05e989ba7168bfaa4146e0d7cb4.tar.gz forums-4adfa4685096f05e989ba7168bfaa4146e0d7cb4.tar.bz2 forums-4adfa4685096f05e989ba7168bfaa4146e0d7cb4.tar.xz forums-4adfa4685096f05e989ba7168bfaa4146e0d7cb4.zip | |
Merge remote-tracking branch 'naderman/ticket/9892' into develop-olympus
* naderman/ticket/9892:
[ticket/9892] Correct copyright year
[ticket/9892] Remove incorrect use of camel case
[ticket/9892] Removing closing php tag from create_schema_files
[ticket/9892] Transaction support for database update sql execution function
[ticket/9892] count is a keyword in firebird, so renaming this alias
[ticket/9892] Q&A CAPTCHA did not work on firebird, so no need to change config
[ticket/9892] Shorten login_attempt key names to avoid firebird length problems
[ticket/9892] Drop Q&A CAPTCHA tables if left in inconsistent state
[ticket/9892] Adding a number of tests for db_tools
[ticket/9892] Table prefix lengths influence index lengths in db_tools
[ticket/9892] Shorten the index names on the q&a captcha
[ticket/9892] column & index name limits, firebird auto increment in db_tools
Diffstat (limited to 'phpBB/includes/auth/auth_db.php')
| -rw-r--r-- | phpBB/includes/auth/auth_db.php | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/phpBB/includes/auth/auth_db.php b/phpBB/includes/auth/auth_db.php index 02c9386f33..fe3ea30b2a 100644 --- a/phpBB/includes/auth/auth_db.php +++ b/phpBB/includes/auth/auth_db.php @@ -72,7 +72,7 @@ function login_db($username, $password, $ip = '', $browser = '', $forwarded_for if (($ip && !$config['ip_login_limit_use_forwarded']) || ($forwarded_for && $config['ip_login_limit_use_forwarded'])) { - $sql = 'SELECT COUNT(attempt_id) AS count + $sql = 'SELECT COUNT(attempt_id) AS attempts FROM ' . LOGIN_ATTEMPT_TABLE . ' WHERE attempt_time > ' . (time() - (int) $config['ip_login_limit_time']); if ($config['ip_login_limit_use_forwarded']) @@ -85,7 +85,7 @@ function login_db($username, $password, $ip = '', $browser = '', $forwarded_for } $result = $db->sql_query($sql); - $attempts = (int) $db->sql_fetchfield('count'); + $attempts = (int) $db->sql_fetchfield('attempts'); $db->sql_freeresult($result); $attempt_data = array( |
