summaryrefslogtreecommitdiff
path: root/riscos/uri.c
diff options
context:
space:
mode:
authorJohn Mark Bell <jmb@netsurf-browser.org>2003-12-26 22:11:28 +0000
committerJohn Mark Bell <jmb@netsurf-browser.org>2003-12-26 22:11:28 +0000
commitd49a18d608bb9cfc779e386d65f942045ee2829c (patch)
tree65be015039fd06a3a685d44f2353d1c772fc89a7 /riscos/uri.c
parent30702d00cbeabcaa17602c9146ba3747d11ebd6c (diff)
downloadnetsurf-d49a18d608bb9cfc779e386d65f942045ee2829c.tar.gz
netsurf-d49a18d608bb9cfc779e386d65f942045ee2829c.tar.bz2
[project @ 2003-12-26 22:11:28 by jmb]
Remove file:/// kludge. No longer needed as libcurl is now sensible svn path=/import/netsurf/; revision=448
Diffstat (limited to 'riscos/uri.c')
-rw-r--r--riscos/uri.c19
1 files changed, 1 insertions, 18 deletions
diff --git a/riscos/uri.c b/riscos/uri.c
index 5494887ee..56780563b 100644
--- a/riscos/uri.c
+++ b/riscos/uri.c
@@ -23,11 +23,9 @@ void ro_uri_message_received(uri_full_message_process* uri_message)
{
uri_h uri_handle;
char* uri_requested;
- char* temp;
struct browser_window* bw;
int uri_length;
- int i;
uri_handle = uri_message->handle;
@@ -49,28 +47,13 @@ void ro_uri_message_received(uri_full_message_process* uri_message)
uri_message->sender);
xuri_request_uri(0, 0, 0, uri_handle, &uri_length);
- uri_requested = xcalloc(uri_length, sizeof(char));
+ uri_requested = xcalloc((unsigned int)uri_length, sizeof(char));
if (uri_requested == NULL)
return;
xuri_request_uri(0, uri_requested, uri_length, uri_handle, NULL);
- /* Kludge for file:/ URLs (changes them into file:/// URLs) */
- if( (strncasecmp(uri_requested, "file:/", 6) == 0) &&
- (strncasecmp(uri_requested, "file://", 7) != 0) ) {
-
- temp = xcalloc(strlen(uri_requested) + 5, sizeof(char));
- strcpy(temp, "file:///");
- for(i=6; i!=strlen(uri_requested); i++) {
-
- temp[i+2] = uri_message->uri[i];
- }
- xfree(uri_requested);
- uri_requested = strdup(temp);
- xfree(temp);
- }
-
bw = create_browser_window(browser_TITLE | browser_TOOLBAR
| browser_SCROLL_X_ALWAYS | browser_SCROLL_Y_ALWAYS, 640, 480, NULL);