Bug 1282750 - Convert AboutCache to use AsyncOpen2() r=honza

This commit is contained in:
Christoph Kerschbaumer 2016-06-28 15:32:20 +02:00
parent 71fde070bb
commit ec2f7f5183

View File

@ -146,7 +146,8 @@ NS_IMETHODIMP nsAboutCache::Channel::AsyncOpen(nsIStreamListener *aListener, nsI
rv = VisitNextStorage();
if (NS_FAILED(rv)) return rv;
rv = mChannel->AsyncOpen(aListener, aContext);
MOZ_ASSERT(!aContext, "asyncOpen2() does not take a context argument");
rv = mChannel->AsyncOpen2(aListener);
if (NS_FAILED(rv)) return rv;
return NS_OK;
@ -159,25 +160,12 @@ NS_IMETHODIMP nsAboutCache::Channel::AsyncOpen2(nsIStreamListener *aListener)
NS_IMETHODIMP nsAboutCache::Channel::Open(nsIInputStream * *_retval)
{
nsresult rv;
if (!mChannel) {
return NS_ERROR_UNEXPECTED;
}
// Kick the walk loop.
rv = VisitNextStorage();
if (NS_FAILED(rv)) return rv;
rv = mChannel->Open(_retval);
if (NS_FAILED(rv)) return rv;
return NS_OK;
return NS_ERROR_NOT_IMPLEMENTED;
}
NS_IMETHODIMP nsAboutCache::Channel::Open2(nsIInputStream * *_retval)
{
return Open(_retval);
return NS_ERROR_NOT_IMPLEMENTED;
}
nsresult