diff options
Diffstat (limited to 'src/map/script.c')
-rw-r--r-- | src/map/script.c | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/src/map/script.c b/src/map/script.c index 3fa32d681..d2ff334bf 100644 --- a/src/map/script.c +++ b/src/map/script.c @@ -3634,10 +3634,14 @@ int script_config_read(char *cfgName) return 0; } -static int db_script_free_code_sub(DBKey key, void *data, va_list ap) +/** + * @see DBApply + */ +static int db_script_free_code_sub(DBKey key, DBData *data, va_list ap) { - if (data) - script_free_code(data); + struct script_code *code = db_data2ptr(data); + if (code) + script_free_code(code); return 0; } |