summaryrefslogtreecommitdiff
path: root/src/core/token.c
diff options
context:
space:
mode:
authorPaul Buetow <paul@buetow.org>2008-11-04 23:43:30 +0000
committerPaul Buetow <paul@buetow.org>2008-11-04 23:43:30 +0000
commit7575536c805e379b009630947e72f636c006751f (patch)
treef8183dac7c3a088a5e6ac1054f226b8510337114 /src/core/token.c
parentd2713783c48ca9fbdd6f4ea3aab03fe856fdd52a (diff)
fixed bugs which happened.
Diffstat (limited to 'src/core/token.c')
-rw-r--r--src/core/token.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/core/token.c b/src/core/token.c
index 3a2e413..a60a790 100644
--- a/src/core/token.c
+++ b/src/core/token.c
@@ -275,6 +275,7 @@ token_new_dummy() {
p_token->c_filename = NULL;
p_token->u_token_id = TOKEN_ID_COUNTER++;
p_token->i_ref_count = 0;
+ p_token->p_array = NULL;
/* Register the token in the garbage collector */
garbage_add_token(p_token);
@@ -290,6 +291,7 @@ token_new_copy(Token *p_token) {
if (p_token_copy == NULL)
ERROR("Memory alloc error");
+ p_token->p_array = NULL;
token_copy_vals(p_token_copy, p_token);
p_token_copy->i_ref_count = 0;