mInst->GetCallbacks(&callbacks); mInst->GetNPP(&npp);
nsresult rv = NS_OK; if(mStreamType != nsPluginStreamType_Seek) rv = CleanUpStream(NPRES_DONE);  if(rv != NPERR_NO_ERROR) return NS_ERROR_FAILURE;
ns4xPluginStreamListener::OnStopBinding(nsIPluginStreamInfo* pluginInfo, nsresult status){    const NPPluginFuncs *callbacks;    NPP                 npp;	NPError error;    pluginInfo->GetURL(&mNPStream.url);    pluginInfo->GetLastModified((PRUint32*)&(mNPStream.lastmodified));    mInst->GetCallbacks(&callbacks);    mInst->GetNPP(&npp);    if (callbacks->destroystream != NULL)    {		// XXX need to convert status to NPReason#if !TARGET_CARBON// pinkerton// relies on routine descriptors, not present in carbon. We need to fix this.        error = CallNPP_DestroyStreamProc(callbacks->destroystream,                                  npp,                                  &mNPStream,                                  NPRES_DONE);		if(error != NPERR_NO_ERROR)			return NS_ERROR_FAILURE;#endif    }	// check to see if we have a call back    if (callbacks->urlnotify != NULL && mNotifyData != nsnull)    {#if !TARGET_CARBON// pinkerton// relies on routine descriptors, not present in carbon. We need to fix this.        CallNPP_URLNotifyProc(callbacks->urlnotify,                              npp,                              mNPStream.url,                              nsPluginReason_Done,                              mNotifyData);#endif    }    return NS_OK;}