if (NS_FAILED(rv)) { FreeGlobals(); return rv; }
InitFontEncodingProperties(void){  nsresult rv;  // load the special encoding resolver  nsCOMPtr<nsIURI> uri;  rv = NS_NewURI(getter_AddRefs(uri), "resource:/res/fonts/fontEncoding.properties");  if (NS_SUCCEEDED(rv)) {    nsCOMPtr<nsIInputStream> in;    rv = NS_OpenURI(getter_AddRefs(in), uri);    if (NS_SUCCEEDED(rv)) {      rv = nsComponentManager::           CreateInstance(NS_PERSISTENTPROPERTIES_CONTRACTID, nsnull,                          NS_GET_IID(nsIPersistentProperties),                          (void**)&gFontEncodingProperties);      if (NS_SUCCEEDED(rv)) {        rv = gFontEncodingProperties->Load(in);      }    }  }  if (NS_FAILED(rv)) {    FreeGlobals();    return rv;  }  return rv;}