summaryrefslogtreecommitdiff
path: root/beos
diff options
context:
space:
mode:
authorVincent Sanders <vince@netsurf-browser.org>2010-03-31 13:59:57 +0000
committerVincent Sanders <vince@netsurf-browser.org>2010-03-31 13:59:57 +0000
commit95e4a737de53dc2f02a2db95b26151d9d494bc0c (patch)
treea9dcb06c696a463f824d61865fb46d6a7bfa755b /beos
parent9f575c590b3c304ab02707ee3378bd2e4f4c9094 (diff)
downloadnetsurf-95e4a737de53dc2f02a2db95b26151d9d494bc0c.tar.gz
netsurf-95e4a737de53dc2f02a2db95b26151d9d494bc0c.tar.bz2
rationalise the usage of the file scheme
svn path=/trunk/netsurf/; revision=10221
Diffstat (limited to 'beos')
-rw-r--r--beos/beos_gui.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/beos/beos_gui.cpp b/beos/beos_gui.cpp
index d506cdfe6..57f81877a 100644
--- a/beos/beos_gui.cpp
+++ b/beos/beos_gui.cpp
@@ -1151,9 +1151,9 @@ utf8_convert_ret utf8_from_local_encoding(const char *string, size_t len,
char *path_to_url(const char *path)
{
- char *r = (char *)malloc(strlen(path) + 7 + 1);
+ char *r = (char *)malloc(strlen(path) + FILE_SCHEME_PREFIX_LEN + 1);
- strcpy(r, "file://");
+ strcpy(r, FILE_SCHEME_PREFIX);
strcat(r, path);
return r;
@@ -1161,7 +1161,7 @@ char *path_to_url(const char *path)
char *url_to_path(const char *url)
{
- return strdup(url + 5);
+ return strdup(url + FILE_SCHEME_PREFIX_LEN);
}
bool cookies_update(const char *domain, const struct cookie_data *data)