shane Sun Oct 19 16:00:53 2003 EDT Modified files: /php-src/ext/standard url.c Log: make parse_url work correctly for file uri's on windows, such as file:///c:/somepath/somefile.txt Index: php-src/ext/standard/url.c diff -u php-src/ext/standard/url.c:1.69 php-src/ext/standard/url.c:1.70 --- php-src/ext/standard/url.c:1.69 Mon Oct 13 00:27:23 2003 +++ php-src/ext/standard/url.c Sun Oct 19 16:00:51 2003 @@ -15,7 +15,7 @@ | Author: Jim Winstead <[EMAIL PROTECTED]> | +----------------------------------------------------------------------+ */ -/* $Id: url.c,v 1.69 2003/10/13 04:27:23 iliaa Exp $ */ +/* $Id: url.c,v 1.70 2003/10/19 20:00:51 shane Exp $ */ #include <stdlib.h> #include <string.h> @@ -126,6 +126,12 @@ s = e + 3; if (!strncasecmp("file", ret->scheme, sizeof("file"))) { if (*(e + 3) == '/') { + /* support windows drive letters as in: + file:///c:/somedir/file.txt + */ + if (*(e + 5) == ':') { + s = e + 4; + } goto nohost; } }
-- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php