if (tmp && tmp == file2) {
if (tmp && (const char *)tmp == file2) {
static PRBool EqualBaseURLs(nsIURI* url1, nsIURI* url2){  nsXPIDLCString host1;  nsXPIDLCString host2;  nsXPIDLCString file1;  nsXPIDLCString file2;  char *  anchor1 = nsnull, * anchor2=nsnull;  PRBool rv = PR_FALSE;    if (url1 && url2) {    // XXX We need to make these strcmps case insensitive.#ifdef NECKO    url1->GetHost(getter_Copies(host1));    url2->GetHost(getter_Copies(host2));#else    url1->GetHost(getter_Shares(host1));    url2->GetHost(getter_Shares(host2));  #endif    if (0 == PL_strcmp(host1, host2)) {#ifdef NECKO      url1->GetPath(getter_Copies(file1));      url2->GetPath(getter_Copies(file2));#else      url1->GetFile(getter_Shares(file1));      url2->GetFile(getter_Shares(file2));#endif      anchor1 = PL_strrchr(file1, '#');	  if (anchor1) {          char * tmp = PL_strstr(file1, file2);	    if (tmp && tmp == file1) {				  return PR_TRUE;		}	  }	  anchor2 = PL_strrchr(file2, '#');	  if (anchor2) {          char * tmp = PL_strstr(file2, file1);	    if (tmp && tmp == file2) {			 				  return PR_TRUE;		}	  }	      if (0 == PL_strcmp(file1, file2)) {          rv = PR_TRUE;	  }    }  // strcmp(host1, host2)  }   // url1 && url2  return rv;}