if(mGlobalHistory) { PRBool isVisited; NS_ENSURE_SUCCESS(mGlobalHistory->IsVisited(aLinkURI, &isVisited), NS_ERROR_FAILURE); if (isVisited) aState = eLinkState_Visited; }
nsresult rv;
nsWebShell::GetLinkState(const char* aLinkURI, nsLinkState& aState){  aState = eLinkState_Unvisited;   if(mGlobalHistory)      {        PRBool isVisited;        NS_ENSURE_SUCCESS(mGlobalHistory->IsVisited(aLinkURI, &isVisited),                          NS_ERROR_FAILURE);        if (isVisited)          aState = eLinkState_Visited;      }   return NS_OK;}