nsCOMPtr<nsIPref> pPref(do_GetService(kPrefCID, &rv));
nsCOMPtr<nsIPref> pPref(do_GetService(NS_PREF_CONTRACTID, &rv));
nsresult DIR_ShutDown()  /* FEs should call this when the app is shutting down. It frees all DIR_Servers regardless of ref count values! */{	nsresult rv = NS_OK;	nsCOMPtr<nsIPref> pPref(do_GetService(kPrefCID, &rv)); 	if (NS_FAILED(rv) || !pPref) 		return NS_ERROR_FAILURE;	pPref->SavePrefFile(nsnull);	if (dir_ServerList)	{		PRInt32 count = dir_ServerList->Count();		PRInt32 i;		for (i = 0; i < count; i++)		{			DIR_DeleteServer((DIR_Server *)(dir_ServerList->ElementAt(i)));		}		delete dir_ServerList;		dir_ServerList = nsnull;	}	return NS_OK;}