summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--desktop/browser.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/desktop/browser.c b/desktop/browser.c
index e7b575100..8735a7ca2 100644
--- a/desktop/browser.c
+++ b/desktop/browser.c
@@ -1420,8 +1420,11 @@ void browser_window_follow_link(struct browser_window *bw,
break;
}
else if (click_boxes[i].box->gadget->type == GADGET_SUBMIT) {
+ struct form *form;
char *url, *href;
- href = click_boxes[i].box->gadget->form->action;
+ form = click_boxes[i].box->gadget->form;
+ if (!form) continue;
+ href = form->action;
if (!href) continue;
url = url_join(href, bw->current_content->data.html.base_url);
if (!url) continue;