diff options
author | celest <celest@54d463be-8e91-2dee-dedb-b68131a5f0ec> | 2005-03-23 15:26:52 +0000 |
---|---|---|
committer | celest <celest@54d463be-8e91-2dee-dedb-b68131a5f0ec> | 2005-03-23 15:26:52 +0000 |
commit | 33b8fd47955eeab26cede233b14d683b8e0491b8 (patch) | |
tree | 041f7df2acc8b46bdb56512f06b0f9706fe6ec29 /src/char_sql/char.c | |
parent | 7d3fedfa5c264169c544fe3ec977229c50e4baa2 (diff) | |
download | hercules-33b8fd47955eeab26cede233b14d683b8e0491b8.tar.gz hercules-33b8fd47955eeab26cede233b14d683b8e0491b8.tar.bz2 hercules-33b8fd47955eeab26cede233b14d683b8e0491b8.tar.xz hercules-33b8fd47955eeab26cede233b14d683b8e0491b8.zip |
* Fixed alot of memory leaks
* Added stray memory cleaning routine to db.c
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/branches/stable@1275 54d463be-8e91-2dee-dedb-b68131a5f0ec
Diffstat (limited to 'src/char_sql/char.c')
-rw-r--r-- | src/char_sql/char.c | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/src/char_sql/char.c b/src/char_sql/char.c index 78467b579..6b122974f 100644 --- a/src/char_sql/char.c +++ b/src/char_sql/char.c @@ -3134,6 +3134,12 @@ int char_lan_config_read(const char *lancfgName){ return 0; } +static int char_db_final(void *key,void *data,va_list ap) +{ + struct mmo_charstatus *p = data; + if (p) aFree(p); + return 0; +} void do_final(void) { printf("Doing final stage...\n"); //mmo_char_sync(); @@ -3162,9 +3168,12 @@ void do_final(void) { delete_session(login_fd); delete_session(char_fd); + numdb_final(char_db_, char_db_final); + exit_dbn(); mysql_close(&mysql_handle); mysql_close(&lmysql_handle); + timer_final(); printf("ok! all done...\n"); } |