- Fixed some of the leaks.. still fixing..
git-svn-id: https://svn.code.sf.net/p/rathena/svn/trunk@6691 54d463be-8e91-2dee-dedb-b68131a5f0ec
This commit is contained in:
parent
a7e5993400
commit
2870364349
@ -22,6 +22,7 @@
|
|||||||
// --------------------------------------------------------------
|
// --------------------------------------------------------------
|
||||||
// ----------------------- Basic Scripts -----------------------
|
// ----------------------- Basic Scripts -----------------------
|
||||||
// -- Adoption NPC [Fredzilla]
|
// -- Adoption NPC [Fredzilla]
|
||||||
|
npc: script.txt
|
||||||
npc: npc/custom/adoption.txt
|
npc: npc/custom/adoption.txt
|
||||||
// -- Auctioneer - Use at own risk [Fredzilla]
|
// -- Auctioneer - Use at own risk [Fredzilla]
|
||||||
// Warning: It dupe items.
|
// Warning: It dupe items.
|
||||||
|
@ -1381,7 +1381,7 @@ int npc_unload (struct npc_data *nd)
|
|||||||
aFree(nd->u.scr.timer_event);
|
aFree(nd->u.scr.timer_event);
|
||||||
if (nd->u.scr.src_id == 0) {
|
if (nd->u.scr.src_id == 0) {
|
||||||
if(nd->u.scr.script) {
|
if(nd->u.scr.script) {
|
||||||
aFree(nd->u.scr.script);
|
script_free_code(nd->u.scr.script);
|
||||||
nd->u.scr.script = NULL;
|
nd->u.scr.script = NULL;
|
||||||
}
|
}
|
||||||
if (nd->u.scr.label_list) {
|
if (nd->u.scr.label_list) {
|
||||||
|
@ -11882,6 +11882,15 @@ int script_config_read(char *cfgName)
|
|||||||
return script_config_read_sub(cfgName);
|
return script_config_read_sub(cfgName);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static int do_final_userfunc_sub (DBKey key,void *data,va_list ap){
|
||||||
|
struct script_code *code = (struct script_code *)data;
|
||||||
|
if(code){
|
||||||
|
script_free_vars( &code->script_vars );
|
||||||
|
aFree( code->script_buf );
|
||||||
|
}
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
|
||||||
/*==========================================
|
/*==========================================
|
||||||
* ŹI—ą
|
* ŹI—ą
|
||||||
*------------------------------------------
|
*------------------------------------------
|
||||||
@ -11894,7 +11903,7 @@ int do_final_script()
|
|||||||
mapreg_db->destroy(mapreg_db,NULL);
|
mapreg_db->destroy(mapreg_db,NULL);
|
||||||
mapregstr_db->destroy(mapregstr_db,NULL);
|
mapregstr_db->destroy(mapregstr_db,NULL);
|
||||||
scriptlabel_db->destroy(scriptlabel_db,NULL);
|
scriptlabel_db->destroy(scriptlabel_db,NULL);
|
||||||
userfunc_db->destroy(userfunc_db,NULL);
|
userfunc_db->destroy(userfunc_db,do_final_userfunc_sub);
|
||||||
if(sleep_db) {
|
if(sleep_db) {
|
||||||
struct linkdb_node *n = (struct linkdb_node *)sleep_db;
|
struct linkdb_node *n = (struct linkdb_node *)sleep_db;
|
||||||
while(n) {
|
while(n) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user