From 30c3f27b0e056afcbf326c20351e62927d453664 Mon Sep 17 00:00:00 2001 From: Ben Kurtovic Date: Tue, 23 Jul 2013 16:58:28 -0400 Subject: [PATCH] Correctly set TagOpenData's default values. --- mwparserfromhell/parser/tokenizer.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/mwparserfromhell/parser/tokenizer.c b/mwparserfromhell/parser/tokenizer.c index 5649803..a02b053 100644 --- a/mwparserfromhell/parser/tokenizer.c +++ b/mwparserfromhell/parser/tokenizer.c @@ -1261,6 +1261,7 @@ Tokenizer_really_parse_tag(Tokenizer* self) PyErr_NoMemory(); return NULL; } + data->context = TAG_NAME; data->pad_first = Textbuffer_new(); data->pad_before_eq = Textbuffer_new(); data->pad_after_eq = Textbuffer_new(); @@ -1268,6 +1269,7 @@ Tokenizer_really_parse_tag(Tokenizer* self) free(data); return NULL; } + data->reset = 0; if (Tokenizer_push(self, LC_TAG_OPEN)) { free(data); return NULL;