summaryrefslogtreecommitdiff
path: root/desktop
diff options
context:
space:
mode:
Diffstat (limited to 'desktop')
-rw-r--r--desktop/browser.c20
1 files changed, 12 insertions, 8 deletions
diff --git a/desktop/browser.c b/desktop/browser.c
index 1f536fe17..04bbc3ac7 100644
--- a/desktop/browser.c
+++ b/desktop/browser.c
@@ -370,18 +370,22 @@ void browser_window_go_post(struct browser_window *bw, const char *url,
error = llcache_handle_retrieve(url2, fetch_flags, referer,
fetch_is_post ? &post : NULL,
NULL, NULL, &l);
- if (error != NSERROR_OK)
+ if (error == NSERROR_NO_FETCH_HANDLER) {
+ gui_launch_url(url2);
+ } else if (error != NSERROR_OK) {
LOG(("Failed to fetch download: %d", error));
+ } else {
+ error = download_context_create(l, bw->window);
+ if (error != NSERROR_OK) {
+ LOG(("Failed creating download context: %d",
+ error));
+ llcache_handle_abort(l);
+ llcache_handle_release(l);
+ }
+ }
free(url2);
- error = download_context_create(l, bw->window);
- if (error != NSERROR_OK) {
- LOG(("Failed creating download context: %d", error));
- llcache_handle_abort(l);
- llcache_handle_release(l);
- }
-
return;
}