summaryrefslogtreecommitdiff
path: root/src/map/script.c
diff options
context:
space:
mode:
authoramber <amber@54d463be-8e91-2dee-dedb-b68131a5f0ec>2005-04-01 06:16:28 +0000
committeramber <amber@54d463be-8e91-2dee-dedb-b68131a5f0ec>2005-04-01 06:16:28 +0000
commit1086946ca3a5c6cf58c2f1e67f0078cd3abbb698 (patch)
treea479094bf3e452d08c631d81b1b44d6b8e097b9d /src/map/script.c
parent12e8d15728ce26f82a985c0a7218a1e9482250d2 (diff)
downloadhercules-1086946ca3a5c6cf58c2f1e67f0078cd3abbb698.tar.gz
hercules-1086946ca3a5c6cf58c2f1e67f0078cd3abbb698.tar.bz2
hercules-1086946ca3a5c6cf58c2f1e67f0078cd3abbb698.tar.xz
hercules-1086946ca3a5c6cf58c2f1e67f0078cd3abbb698.zip
Fixed some memory corruptions [MouseJstr]
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/branches/stable@1370 54d463be-8e91-2dee-dedb-b68131a5f0ec
Diffstat (limited to 'src/map/script.c')
-rw-r--r--src/map/script.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/map/script.c b/src/map/script.c
index 8a1672c06..1a0a1d1c1 100644
--- a/src/map/script.c
+++ b/src/map/script.c
@@ -52,7 +52,7 @@
(t)=conv_num(st,&(st->stack->stack_data[st->start+(n)]));
enum { LABEL_NEXTLINE=1,LABEL_START };
-static unsigned char * script_buf;
+static unsigned char * script_buf = NULL;
static int script_pos,script_size;
char *str_buf;
@@ -65,7 +65,7 @@ static struct str_data_struct {
int (*func)(struct script_state *);
int val;
int next;
-} *str_data;
+} *str_data = NULL;
int str_num=LABEL_START,str_data_size;
int str_hash[16];
@@ -7813,8 +7813,8 @@ int do_final_script()
{
if(mapreg_dirty>=0)
script_save_mapreg();
- if(script_buf)
- aFree(script_buf);
+// if(script_buf)
+// aFree(script_buf);
if(mapreg_db)
numdb_final(mapreg_db,mapreg_db_final);