summaryrefslogtreecommitdiff
path: root/src/login
diff options
context:
space:
mode:
authorxantara <xantara@54d463be-8e91-2dee-dedb-b68131a5f0ec>2012-01-23 05:13:59 +0000
committerxantara <xantara@54d463be-8e91-2dee-dedb-b68131a5f0ec>2012-01-23 05:13:59 +0000
commite8f32370d3ce62dd46af7a21ecfb49f83a404aea (patch)
tree429bae5464ba5cbabeabf52091c1853564692f7c /src/login
parent8756ba5d50270bbad6ad7065a05a1329ef86878b (diff)
downloadhercules-e8f32370d3ce62dd46af7a21ecfb49f83a404aea.tar.gz
hercules-e8f32370d3ce62dd46af7a21ecfb49f83a404aea.tar.bz2
hercules-e8f32370d3ce62dd46af7a21ecfb49f83a404aea.tar.xz
hercules-e8f32370d3ce62dd46af7a21ecfb49f83a404aea.zip
` Added renaming support for the remaining 'ragnarok' tables in the inter_athena.conf file - bugreport:3317
-- Includes: homunculus, skill_homunculus, mercenary, mercenary_owner, ragsrvinfo ` Fixed a typo regarding the homunculus_db git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@15508 54d463be-8e91-2dee-dedb-b68131a5f0ec
Diffstat (limited to 'src/login')
-rw-r--r--src/login/loginlog_sql.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/login/loginlog_sql.c b/src/login/loginlog_sql.c
index 055594083..e4312d5ea 100644
--- a/src/login/loginlog_sql.c
+++ b/src/login/loginlog_sql.c
@@ -23,7 +23,7 @@ static char log_db_username[32] = "";
static char log_db_password[32] = "";
static char log_db_database[32] = "";
static char log_codepage[32] = "";
-static char loginlog_table[256] = "loginlog";
+static char log_login_db[256] = "loginlog";
static Sql* sql_handle = NULL;
static bool enabled = false;
@@ -38,7 +38,7 @@ unsigned long loginlog_failedattempts(uint32 ip, unsigned int minutes)
return 0;
if( SQL_ERROR == Sql_Query(sql_handle, "SELECT count(*) FROM `%s` WHERE `ip` = '%s' AND `rcode` = '1' AND `time` > NOW() - INTERVAL %d MINUTE",
- loginlog_table, ip2str(ip,NULL), minutes) )// how many times failed account? in one ip.
+ log_login_db, ip2str(ip,NULL), minutes) )// how many times failed account? in one ip.
Sql_ShowDebug(sql_handle);
if( SQL_SUCCESS == Sql_NextRow(sql_handle) )
@@ -69,7 +69,7 @@ void login_log(uint32 ip, const char* username, int rcode, const char* message)
retcode = Sql_Query(sql_handle,
"INSERT INTO `%s`(`time`,`ip`,`user`,`rcode`,`log`) VALUES (NOW(), '%s', '%s', '%d', '%s')",
- loginlog_table, ip2str(ip,NULL), esc_username, rcode, message);
+ log_login_db, ip2str(ip,NULL), esc_username, rcode, message);
if( retcode != SQL_SUCCESS )
Sql_ShowDebug(sql_handle);
@@ -175,8 +175,8 @@ bool loginlog_config_read(const char* key, const char* value)
if( strcmpi(key, "log_codepage") == 0 )
safestrncpy(log_codepage, value, sizeof(log_codepage));
else
- if( strcmpi(key, "loginlog_db") == 0 )
- safestrncpy(loginlog_table, value, sizeof(loginlog_table));
+ if( strcmpi(key, "log_login_db") == 0 )
+ safestrncpy(log_login_db, value, sizeof(log_login_db));
else
return false;