Re: streams file uri under windows
| From: | Christian Schneider | Date: | Tue, 26 Oct 2004 18:08:27 +0000 |
| Subject: | Re: streams file uri under windows | ||
| References: | 1 | Groups: | php.internals |
| Request: | Send a blank email to internals+get-13534@lists.php.net to get a copy of this message | ||
Rob Richards wrote:
Index: streams.c =================================================================== RCS file: /repository/php-src/main/streams/streams.c,v retrieving revision 1.68 diff -r1.68 streams.c 1496c1496 < if (protocol && path[n+1] == '/' && path[n+2] == '/' && path[n+4] != ':') { ---I'm not an export on that piece of code but passing file:// to this function could cause problems. You should at least move the path[n+3] != '/' to before the n+4 test and I think you should also make sure that n+3 is not '\0' as otherwise n+4 could be beyond the end of the string, no? Just my $.2, - Chrisif (protocol && path[n+1] == '/' && path[n+2] == '/' && path[n+4] != ':'&& path[n+3] != '/') {