aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorjcid <devnull@localhost>2008-04-14 21:11:00 +0200
committerjcid <devnull@localhost>2008-04-14 21:11:00 +0200
commit9c133c549782b93b16769de0ffad1615c34feec5 (patch)
treeb5f2c9939b63744008021e51354ae658aacc9e61 /src
parentd7d9e0cdc3c89fa6091a98546ec95bbfaf5b2163 (diff)
- Fixed potential uninitialized input variable in a_Html_form_event_handler.
Diffstat (limited to 'src')
-rw-r--r--src/html.cc4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/html.cc b/src/html.cc
index a2869193..7d5f7f03 100644
--- a/src/html.cc
+++ b/src/html.cc
@@ -4356,7 +4356,7 @@ void a_Html_form_event_handler(void *data, form::Form *form_receiver,
{
int form_index, input_idx = -1, idx;
DilloHtmlForm *form = NULL;
- DilloHtmlInput *input;
+ DilloHtmlInput *input = NULL;
DilloHtml *html = (DilloHtml*)data;
MSG("Html_form_event_handler %p %p\n", html, form_receiver);
@@ -4377,7 +4377,7 @@ void a_Html_form_event_handler(void *data, form::Form *form_receiver,
break;
}
}
- if (form_index == html->forms->size()) {
+ if (!input) {
MSG("a_Html_form_event_handler: ERROR, form not found!\n");
} else if (input->type == DILLO_HTML_INPUT_FILE) {
/* read the file into cache */