diff options
author | skotlex <skotlex@54d463be-8e91-2dee-dedb-b68131a5f0ec> | 2006-03-01 20:51:21 +0000 |
---|---|---|
committer | skotlex <skotlex@54d463be-8e91-2dee-dedb-b68131a5f0ec> | 2006-03-01 20:51:21 +0000 |
commit | de5d6cb3e5c319f09c9014ce2a3bcd9041ad3323 (patch) | |
tree | eed01479812ee65b57512d03e8822e53302b50ea /src/map/map.c | |
parent | 094168fde61dd27a21b9bf91c162a8de6d37c58c (diff) | |
download | hercules-de5d6cb3e5c319f09c9014ce2a3bcd9041ad3323.tar.gz hercules-de5d6cb3e5c319f09c9014ce2a3bcd9041ad3323.tar.bz2 hercules-de5d6cb3e5c319f09c9014ce2a3bcd9041ad3323.tar.xz hercules-de5d6cb3e5c319f09c9014ce2a3bcd9041ad3323.zip |
- Added sql init for the mapreg handle.
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@5416 54d463be-8e91-2dee-dedb-b68131a5f0ec
Diffstat (limited to 'src/map/map.c')
-rw-r--r-- | src/map/map.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/src/map/map.c b/src/map/map.c index bf77e213d..429c1b85a 100644 --- a/src/map/map.c +++ b/src/map/map.c @@ -3542,11 +3542,12 @@ int map_sql_init(void){ #ifdef MAPREGSQL
// [zBuffer] SQL Mapreg connection start
ShowInfo("Connect Mapreg DB Server....\n");
- if(!mysql_real_connect(&mapregsql_handle, map_server_ip, map_server_id, map_server_pw,
+ mysql_init(&mapregsql_handle);
+ if(!mysql_real_connect(&mapregsql_handle, map_server_ip, map_server_id, map_server_pw,
map_server_db ,map_server_port, (char *)NULL, 0)) {
//pointer check
- ShowSQL("DB error - %s\n",mysql_error(&mapregsql_handle));
- exit(1);
+ ShowSQL("DB error - %s\n",mysql_error(&mapregsql_handle));
+ exit(1);
} else {
ShowStatus ("Connect success! (Mapreg DB Connection)\n");
if( strlen(default_codepage) > 0 ) {
|