summaryrefslogtreecommitdiff
path: root/src/login
diff options
context:
space:
mode:
Diffstat (limited to 'src/login')
-rw-r--r--src/login/account_sql.c2
-rw-r--r--src/login/login.c7
2 files changed, 5 insertions, 4 deletions
diff --git a/src/login/account_sql.c b/src/login/account_sql.c
index ae80163af..f89147334 100644
--- a/src/login/account_sql.c
+++ b/src/login/account_sql.c
@@ -486,7 +486,6 @@ static bool account_db_sql_iter_next(AccountDBIterator* self, struct mmo_account
AccountDBIterator_SQL* iter = (AccountDBIterator_SQL*)self;
AccountDB_SQL* db = (AccountDB_SQL*)iter->db;
Sql* sql_handle = db->accounts;
- int account_id;
char* data;
// get next account ID
@@ -501,6 +500,7 @@ static bool account_db_sql_iter_next(AccountDBIterator* self, struct mmo_account
SQL_SUCCESS == Sql_GetData(sql_handle, 0, &data, NULL) &&
data != NULL )
{// get account data
+ int account_id;
account_id = atoi(data);
if( mmo_auth_fromsql(db, acc, account_id) )
{
diff --git a/src/login/login.c b/src/login/login.c
index 1ced8cb93..54f066b53 100644
--- a/src/login/login.c
+++ b/src/login/login.c
@@ -1606,10 +1606,11 @@ int login_config_read(const char* cfgName)
ShowInfo("Console Silent Setting: %d\n", atoi(w2));
}
else if( !strcmpi(w1, "bind_ip") ) {
- char ip_str[16];
login_config.login_ip = host2ip(w2);
- if( login_config.login_ip )
+ if( login_config.login_ip ) {
+ char ip_str[16];
ShowStatus("Login server binding IP address : %s -> %s\n", w2, ip2str(login_config.login_ip, ip_str));
+ }
}
else if( !strcmpi(w1, "login_port") ) {
login_config.login_port = (uint16)atoi(w2);
@@ -1654,10 +1655,10 @@ int login_config_read(const char* cfgName)
else if(!strcmpi(w1, "client_hash")) {
int group = 0;
char md5[33];
- int i;
if (sscanf(w2, "%d, %32s", &group, md5) == 2) {
struct client_hash_node *nnode;
+ int i;
CREATE(nnode, struct client_hash_node, 1);
for (i = 0; i < 32; i += 2) {