diff --git a/docshell/base/nsWebShell.cpp b/docshell/base/nsWebShell.cpp index f2d1b3a1d946..6c1ed1c6b69d 100644 --- a/docshell/base/nsWebShell.cpp +++ b/docshell/base/nsWebShell.cpp @@ -3390,7 +3390,7 @@ nsWebShell::OnEndDocumentLoad(nsIDocumentLoader* loader, hostStr.SetString(host); nsAllocator::Free(host); PRInt32 dotLoc = -1; - dotLoc = hostStr.Find('.'); + dotLoc = hostStr.FindChar('.'); PRBool retry = PR_FALSE; if (-1 == dotLoc) { hostStr.Insert("www.", 0, 4); diff --git a/extensions/cookie/nsCookie.cpp b/extensions/cookie/nsCookie.cpp index 312d0b3f4a77..119baf0e7f4b 100644 --- a/extensions/cookie/nsCookie.cpp +++ b/extensions/cookie/nsCookie.cpp @@ -1755,7 +1755,7 @@ cookie_LoadPermissions() { } int hostIndex, permissionIndex; hostIndex = 0; - if ((permissionIndex=buffer->Find('\t', hostIndex)+1) == 0) { + if ((permissionIndex=buffer->FindChar('\t', PR_FALSE,hostIndex)+1) == 0) { delete buffer; continue; } @@ -1924,12 +1924,12 @@ cookie_LoadCookies() { } int hostIndex, isDomainIndex, pathIndex, xxxIndex, expiresIndex, nameIndex, cookieIndex; hostIndex = 0; - if ((isDomainIndex=buffer->Find('\t', hostIndex)+1) == 0 || - (pathIndex=buffer->Find('\t', isDomainIndex)+1) == 0 || - (xxxIndex=buffer->Find('\t', pathIndex)+1) == 0 || - (expiresIndex=buffer->Find('\t', xxxIndex)+1) == 0 || - (nameIndex=buffer->Find('\t', expiresIndex)+1) == 0 || - (cookieIndex=buffer->Find('\t', nameIndex)+1) == 0 ) { + if ((isDomainIndex=buffer->FindChar('\t', PR_FALSE,hostIndex)+1) == 0 || + (pathIndex=buffer->FindChar('\t', PR_FALSE,isDomainIndex)+1) == 0 || + (xxxIndex=buffer->FindChar('\t', PR_FALSE,pathIndex)+1) == 0 || + (expiresIndex=buffer->FindChar('\t', PR_FALSE,xxxIndex)+1) == 0 || + (nameIndex=buffer->FindChar('\t', PR_FALSE,expiresIndex)+1) == 0 || + (cookieIndex=buffer->FindChar('\t', PR_FALSE,nameIndex)+1) == 0 ) { delete buffer; continue; } @@ -2158,7 +2158,7 @@ cookie_FindValueInArgs(nsAutoString results, char* name) { return nsAutoString("").ToNewCString(); } start += PL_strlen(name); /* get passed the |name| part */ - length = results.Find('|', start) - start; + length = results.FindChar('|', PR_FALSE,start) - start; results.Mid(value, start, length); return value.ToNewCString(); } diff --git a/netwerk/protocol/ftp/src/nsFtpConnectionThread.cpp b/netwerk/protocol/ftp/src/nsFtpConnectionThread.cpp index 0f12398c1442..71f21d995136 100644 --- a/netwerk/protocol/ftp/src/nsFtpConnectionThread.cpp +++ b/netwerk/protocol/ftp/src/nsFtpConnectionThread.cpp @@ -937,12 +937,12 @@ nsFtpConnectionThread::R_pwd() { PRInt32 start; if (path.First() != '/') { - start = path.Find('/'); + start = path.FindChar('/'); if (start > -1) { path.Right(ptr, start); } else { // if we couldn't find a slash, check for back slashes and switch them out. - PRInt32 start = path.Find("\\"); + PRInt32 start = path.FindChar('\\'); if (start > -1) { path.ReplaceChar("\\", '/'); } diff --git a/netwerk/protocol/http/src/nsHTTPResponseListener.cpp b/netwerk/protocol/http/src/nsHTTPResponseListener.cpp index 767acc4789bd..02137ff16137 100644 --- a/netwerk/protocol/http/src/nsHTTPResponseListener.cpp +++ b/netwerk/protocol/http/src/nsHTTPResponseListener.cpp @@ -417,7 +417,7 @@ nsresult nsHTTPResponseListener::ParseStatusLine(nsIBufferInputStream* in, // Parse the HTTP-Version:: "HTTP" "/" 1*DIGIT "." 1*DIGIT // - offset = mHeaderBuffer.Find(' '); + offset = mHeaderBuffer.FindChar(' '); (void) mHeaderBuffer.Left(str, offset); if (!str.Length()) { // The status line is bogus... @@ -437,7 +437,7 @@ nsresult nsHTTPResponseListener::ParseStatusLine(nsIBufferInputStream* in, // PRInt32 statusCode; - offset = mHeaderBuffer.Find(' '); + offset = mHeaderBuffer.FindChar(' '); (void) mHeaderBuffer.Left(str, offset); if (3 != str.Length()) { // The status line is bogus... @@ -613,7 +613,7 @@ nsresult nsHTTPResponseListener::ParseHTTPHeader(nsIBufferInputStream* in, nsAutoString headerKey(eOneByte); nsCOMPtr headerAtom; - colonOffset = mHeaderBuffer.Find(':'); + colonOffset = mHeaderBuffer.FindChar(':'); if (-1 == colonOffset) { // // The header is malformed... Just clear it. @@ -686,7 +686,7 @@ nsresult nsHTTPResponseListener::ProcessHeader(nsIAtom* aHeader, // // Set the content-type in the HTTPChannel... // - semicolon = aValue.Find(';'); + semicolon = aValue.FindChar(';'); if (-1 != semicolon) { aValue.Left(buffer, semicolon); mConnection->SetContentType(buffer.GetBuffer()); diff --git a/webshell/src/nsWebShell.cpp b/webshell/src/nsWebShell.cpp index f2d1b3a1d946..6c1ed1c6b69d 100644 --- a/webshell/src/nsWebShell.cpp +++ b/webshell/src/nsWebShell.cpp @@ -3390,7 +3390,7 @@ nsWebShell::OnEndDocumentLoad(nsIDocumentLoader* loader, hostStr.SetString(host); nsAllocator::Free(host); PRInt32 dotLoc = -1; - dotLoc = hostStr.Find('.'); + dotLoc = hostStr.FindChar('.'); PRBool retry = PR_FALSE; if (-1 == dotLoc) { hostStr.Insert("www.", 0, 4);