NS_IMETHODIMP HttpChannelParent::OnStatus(nsIRequest *aRequest, nsISupports *aContext, nsresult aStatus, const PRUnichar *aStatusArg) { if (mIPCClosed || !SendOnStatus(aStatus, nsString(aStatusArg))) return NS_ERROR_UNEXPECTED; return NS_OK; }
NS_IMETHODIMP HttpChannelParent::OnStatus(nsIRequest *aRequest, nsISupports *aContext, nsresult aStatus, const PRUnichar *aStatusArg) { // If this precedes OnDataAvailable, store and ODA will send to child. if (aStatus == nsISocketTransport::STATUS_RECEIVING_FROM || aStatus == nsITransport::STATUS_READING) { mStoredStatus = aStatus; return NS_OK; } // Otherwise, send to child now if (mIPCClosed || !SendOnStatus(aStatus)) return NS_ERROR_UNEXPECTED; return NS_OK; }