Bug 1430237 - remove newSimpleNestedURI from nsINetUtil, r?mayhemer
MozReview-Commit-ID: 74RsNo60Kfh
--- a/netwerk/base/nsINetUtil.idl
+++ b/netwerk/base/nsINetUtil.idl
@@ -78,23 +78,16 @@ interface nsINetUtil : nsISupports
/**
* Take aURI and produce an immutable version of it for the caller. If aURI
* is immutable this will be aURI itself; otherwise this will be a clone,
* marked immutable if possible. Passing null to this method is allowed; in
* that case it will return null.
*/
nsIURI toImmutableURI(in nsIURI aURI);
- /**
- * Create a simple nested URI using the result of
- * toImmutableURI on the passed-in aURI which may not be null.
- * Note: The return URI will not have had its spec set yet.
- */
- nsIURI newSimpleNestedURI(in nsIURI aURI);
-
/** Escape every character with its %XX-escaped equivalent */
const unsigned long ESCAPE_ALL = 0;
/** Leave alphanumeric characters intact and %XX-escape all others */
const unsigned long ESCAPE_XALPHAS = 1;
/** Leave alphanumeric characters intact, convert spaces to '+',
%XX-escape all others */
--- a/netwerk/base/nsIOService.cpp
+++ b/netwerk/base/nsIOService.cpp
@@ -1570,29 +1570,16 @@ nsIOService::ToImmutableURI(nsIURI* uri,
nsresult rv = NS_EnsureSafeToReturn(uri, result);
NS_ENSURE_SUCCESS(rv, rv);
NS_TryToSetImmutable(*result);
return NS_OK;
}
NS_IMETHODIMP
-nsIOService::NewSimpleNestedURI(nsIURI* aURI, nsIURI** aResult)
-{
- NS_ENSURE_ARG(aURI);
-
- nsCOMPtr<nsIURI> safeURI;
- nsresult rv = NS_EnsureSafeToReturn(aURI, getter_AddRefs(safeURI));
- NS_ENSURE_SUCCESS(rv, rv);
-
- NS_IF_ADDREF(*aResult = new nsSimpleNestedURI(safeURI));
- return *aResult ? NS_OK : NS_ERROR_OUT_OF_MEMORY;
-}
-
-NS_IMETHODIMP
nsIOService::SetManageOfflineStatus(bool aManage)
{
LOG(("nsIOService::SetManageOfflineStatus aManage=%d\n", aManage));
mManageLinkStatus = aManage;
// When detection is not activated, the default connectivity state is true.
if (!mManageLinkStatus) {
SetConnectivityInternal(true);