summaryrefslogtreecommitdiff
path: root/frontends/riscos
diff options
context:
space:
mode:
Diffstat (limited to 'frontends/riscos')
-rw-r--r--frontends/riscos/download.c10
-rw-r--r--frontends/riscos/gui.c4
2 files changed, 8 insertions, 6 deletions
diff --git a/frontends/riscos/download.c b/frontends/riscos/download.c
index 7dd61b7b4..1a0249e20 100644
--- a/frontends/riscos/download.c
+++ b/frontends/riscos/download.c
@@ -33,7 +33,6 @@
#include <assert.h>
#include <string.h>
#include <time.h>
-#include <curl/curl.h>
#include <libwapcaplet/libwapcaplet.h>
#include "oslib/mimemap.h"
@@ -53,6 +52,7 @@
#include "utils/utf8.h"
#include "utils/utils.h"
#include "utils/string.h"
+#include "utils/url.h"
#include "utils/corestrings.h"
#include "netsurf/download.h"
#include "desktop/download.h"
@@ -239,11 +239,11 @@ static nserror download_ro_filetype(download_context *ctx, bits *ftype_out)
lwc_string *path = nsurl_get_component(url, NSURL_PATH);
if (path != NULL && lwc_string_length(path) != 0) {
char *raw_path;
- raw_path = curl_unescape(lwc_string_data(path),
- lwc_string_length(path));
- if (raw_path != NULL) {
+ if (url_unescape(lwc_string_data(path),
+ lwc_string_length(path),
+ &raw_path) == NSERROR_OK) {
ftype = ro_filetype_from_unix_path(raw_path);
- curl_free(raw_path);
+ free(raw_path);
}
}
}
diff --git a/frontends/riscos/gui.c b/frontends/riscos/gui.c
index 2b369ec8c..f55392f99 100644
--- a/frontends/riscos/gui.c
+++ b/frontends/riscos/gui.c
@@ -1513,7 +1513,9 @@ static nserror ro_nsurl_to_path(struct nsurl *url, char **path_out)
return NSERROR_BAD_PARAMETER;
}
- res = url_unescape(lwc_string_data(urlpath), &unpath);
+ res = url_unescape(lwc_string_data(urlpath),
+ lwc_string_length(urlpath),
+ &unpath);
lwc_string_unref(urlpath);
if (res != NSERROR_OK) {
return res;