w3m

Unnamed repository; edit this file to name it for gitweb.
git clone https://logand.com/git/w3m.git/
Log | Files | Refs | README

commit 2da45843c00d2267a9bbc640c943752989cc346e
parent 86a14cd5141d5665b1a3f3e3ba002baf83b7b954
Author: ukai <ukai>
Date:   Mon,  8 Dec 2003 16:17:19 +0000

[w3m-dev 04024] fix: drive letter
* url.c (parseURL2): fix for SUPPORT_DOS_DRIVE_PREFIX
From: WATANABE Katsuyuki <knabe@sannet.ne.jp>

Diffstat:
MChangeLog | 5+++++
Murl.c | 15+++++++++++++--
2 files changed, 18 insertions(+), 2 deletions(-)

diff --git a/ChangeLog b/ChangeLog @@ -1,3 +1,8 @@ +2003-12-09 WATANABE Katsuyuki <knabe@sannet.ne.jp> + + * [w3m-dev 04024] fix: drive letter + * url.c (parseURL2): fix for SUPPORT_DOS_DRIVE_PREFIX + 2003-12-09 YONETANI Tomokazu <qhwt@myrealbox.com> * [w3m-dev 04022] $^ diff --git a/url.c b/url.c @@ -1001,8 +1001,19 @@ parseURL2(char *url, ParsedURL *pu, ParsedURL *current) } return; } - if (pu->scheme == SCM_LOCAL) - pu->file = file_quote(expandName(file_unquote(pu->file))); + if (pu->scheme == SCM_LOCAL) { + char *q = expandName(file_unquote(pu->file)); +#ifdef SUPPORT_DOS_DRIVE_PREFIX + Str drive; + if (IS_ALPHA(q[0]) && q[1] == ':') { + drive = Strnew_charp_n(q, 2); + Strcat_charp(drive, file_quote(q+2)); + pu->file = drive->ptr; + } + else +#endif + pu->file = file_quote(q); + } if (current && (pu->scheme == current->scheme || (pu->scheme == SCM_FTP && current->scheme == SCM_FTPDIR) ||