working on bug 37616, Retire SetRelativePath, Resolve now uses ExtractScheme from nsURLHelper, r=warren@netscape.com

This commit is contained in:
andreas.otte%primus-online.de 2000-05-07 10:56:33 +00:00
parent 186c13552e
commit 0617f66909

View File

@ -681,12 +681,10 @@ nsStdURL::Resolve(const char *relativePath, char **result)
if (!relativePath) return NS_ERROR_NULL_POINTER;
// Make sure that if there is a : its before other delimiters
// If not then its an absolute case
static const char delimiters[] = "/;?#:";
char* brk = PL_strpbrk(relativePath, delimiters);
if (brk && (*brk == ':')) // This is an absolute case
{
nsXPIDLCString scheme;
rv = ExtractURLScheme(relativePath, nsnull, nsnull, getter_Copies(scheme));
if (NS_SUCCEEDED(rv)) {
// then aSpec is absolute
rv = DupString(result, relativePath);
char* path = PL_strstr(*result,"://");
if (path) {