aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorjcid <devnull@localhost>2008-01-08 13:16:28 +0100
committerjcid <devnull@localhost>2008-01-08 13:16:28 +0100
commit1637de6b9561d80b5cfceb2a675fc0ac3364aabe (patch)
tree0040f1bb0a727b971ca2277b8aa36961fced29cd /src
parent445f55b9280aba6357488e2e466d71697f77e400 (diff)
Fixed a crash with SLECT code on options with no value.
Diffstat (limited to 'src')
-rw-r--r--src/html.cc3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/html.cc b/src/html.cc
index 740f49ed..8684507e 100644
--- a/src/html.cc
+++ b/src/html.cc
@@ -3808,7 +3808,8 @@ static void Html_submit_form2(DilloHtml *html, DilloHtmlForm *form,
if (sel_res->isSelected(i)) {
DilloHtmlOption *option =
input->select->options->get (i);
- Html_append_input(DataStr, input->name, option->value);
+ char *val = option->value ? option->value : option->content;
+ Html_append_input(DataStr, input->name, val);
}
}
break;