nsPluginMode * mode; mOwner->GetMode(mode); if (*mode == nsPluginMode_Embedded)
nsPluginMode mode; mOwner->GetMode(&mode); if (mode == nsPluginMode_Embedded)
nsPluginStreamListenerPeer::OnStartRequest(nsIChannel* channel, nsISupports* aContext){  nsresult  rv = NS_OK;  char* aContentType = nsnull;  rv = channel->GetContentType(&aContentType);  if (NS_FAILED(rv)) return rv;  nsCOMPtr<nsIURI> aURL;  rv = channel->GetURI(getter_AddRefs(aURL));  if (NS_FAILED(rv)) return rv;  if (nsnull != aContentType)	  mPluginStreamInfo->SetContentType(aContentType);  nsPluginWindow    *window = nsnull;  // if we don't have an nsIPluginInstance (mInstance), it means  // we weren't able to load a plugin previously because we  // didn't have the mimetype.  Now that we do (aContentType),  // we'll try again with SetUpPluginInstance()   // which is called by InstantiateEmbededPlugin()  // NOTE: we don't want to try again if we didn't get the MIME type this time  if ((nsnull == mInstance) && (nsnull != mOwner) && (nsnull != aContentType))  {    mOwner->GetInstance(mInstance);    mOwner->GetWindow(window);    if ((nsnull == mInstance) && (nsnull != mHost) && (nsnull != window))    {      // determine if we need to try embedded again. FullPage takes a different code path      nsPluginMode * mode;      mOwner->GetMode(mode);      if (*mode == nsPluginMode_Embedded)        rv = mHost->InstantiateEmbededPlugin(aContentType, aURL, mOwner);      else        rv = mHost->SetUpPluginInstance(aContentType, aURL, mOwner);      if (NS_OK == rv)      {		// GetInstance() adds a ref        mOwner->GetInstance(mInstance);        if (nsnull != mInstance)        {          mInstance->Start();          mOwner->CreateWidget();          // If we've got a native window, the let the plugin know          // about it.          if (window->window)            mInstance->SetWindow(window);        }      }    }  }  nsCRT::free(aContentType);  //  // Set up the stream listener...  //  PRInt32 length;  rv = channel->GetContentLength(&length);  // it's possible for the server to not send a Content-Length.  We should  // still work in this case.  if (NS_FAILED(rv)) {    mPluginStreamInfo->SetLength(-1);  }  else {    mPluginStreamInfo->SetLength(length);  }  rv = SetUpStreamListener(channel, aURL);  if (NS_FAILED(rv)) return rv;  return rv;}