nsresult rv = NS_OK; nsCOMPtr<nsICachingChannel> cacheChannel = do_QueryInterface(request); nsCOMPtr<nsIFile> localFile; nsXPIDLCString pathAndFilename;     if (cacheChannel) { rv = cacheChannel->GetCacheFile(getter_AddRefs(localFile)); if (NS_SUCCEEDED(rv)) { localFile->GetPath(getter_Copies(pathAndFilename)); mPluginStreamInfo->SetLocalCachedFile(pathAndFilename); } }   nsCOMPtr<nsIByteRangeRequest> brr = do_QueryInterface(request); if (brr) { PRInt32 absoluteOffset = 0; brr->GetStartRange(&absoluteOffset);  nsPRUintKey key(absoluteOffset);  if (!mDataForwardToRequest) return NS_ERROR_FAILURE;  (void) mDataForwardToRequest->Remove(&key); }    if (--mPendingRequests > 0) return NS_OK;   PRUint32 magicNumber = 0; nsCOMPtr<nsISupportsPRUint32> container = do_QueryInterface(aContext); if (container) container->GetData(&magicNumber);  if (magicNumber == MAGIC_REQUEST_CONTEXT) {  return NS_OK; }  if(!mPStreamListener) return NS_ERROR_FAILURE;  if (!pathAndFilename) mPluginStreamInfo->GetLocalCachedFile(getter_Copies(pathAndFilename));  if (!pathAndFilename || 0 == *pathAndFilename) {  nsCOMPtr<nsIFileChannel> fileChannel = do_QueryInterface(request); if (fileChannel) fileChannel->GetFile(getter_AddRefs(localFile)); if (localFile) localFile->GetPath(getter_Copies(pathAndFilename));  mPluginStreamInfo->SetLocalCachedFile(pathAndFilename); }  if (pathAndFilename) OnFileAvailable(pathAndFilename);  nsCOMPtr<nsIURI> aURL; nsCOMPtr<nsIChannel> channel = do_QueryInterface(request); if (!channel) return NS_ERROR_FAILURE;  rv = channel->GetURI(getter_AddRefs(aURL)); if (NS_FAILED(rv)) return rv;  nsXPIDLCString urlString; rv = aURL->GetSpec(getter_Copies(urlString)); if (NS_SUCCEEDED(rv)) mPluginStreamInfo->SetURL(urlString);   nsXPIDLCString aContentType; rv = channel->GetContentType(getter_Copies(aContentType)); if (NS_FAILED(rv)) return rv;  if (aContentType) mPluginStreamInfo->SetContentType(aContentType);  if (mStartBinding) {  mPStreamListener->OnStopBinding((nsIPluginStreamInfo*)mPluginStreamInfo, aStatus); } else {  mPStreamListener->OnStartBinding((nsIPluginStreamInfo*)mPluginStreamInfo); mPStreamListener->OnStopBinding((nsIPluginStreamInfo*)mPluginStreamInfo, aStatus); }
nsPluginCacheListener::OnStopRequest(nsIRequest *request,                                      nsISupports* aContext,                                      nsresult aStatus){  return NS_OK;}