From 448b0275ae4d62b31f64e3c6399d4fb5a045315c Mon Sep 17 00:00:00 2001 From: Vincent Sanders Date: Fri, 16 Apr 2010 23:56:53 +0000 Subject: Fix file: handling on risc os, gtk, windows and framebuffer frontends svn path=/trunk/netsurf/; revision=10419 --- content/fetchers/fetch_curl.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'content') diff --git a/content/fetchers/fetch_curl.c b/content/fetchers/fetch_curl.c index e3f3d492b..aad0b603c 100644 --- a/content/fetchers/fetch_curl.c +++ b/content/fetchers/fetch_curl.c @@ -1155,8 +1155,7 @@ bool fetch_curl_process_headers(struct curl_fetch_info *f) /* find MIME type from filetype for local files */ if (strncmp(f->url, FILE_SCHEME_PREFIX, FILE_SCHEME_PREFIX_LEN) == 0) { struct stat s; - char *url_path = curl_unescape(f->url + FILE_SCHEME_PREFIX_LEN, - (int) strlen(f->url + FILE_SCHEME_PREFIX_LEN)); + char *url_path = url_to_path(f->url); LOG(("Obtaining mime type for file %s", url_path)); @@ -1209,7 +1208,7 @@ bool fetch_curl_process_headers(struct curl_fetch_info *f) } if (url_path != NULL) - curl_free(url_path); + free(url_path); } if (f->abort) -- cgit v1.2.3