if((*sgProduct.szProxyServer != '\0') && (*sgProduct.szProxyPort != '\0'))
if((*diAdvancedSettings.szProxyServer != '\0') && (*diAdvancedSettings.szProxyPort != '\0'))
long RetrieveArchives(){  DWORD     dwIndex0;  DWORD     dwCounter;  siC       *siCObject = NULL;  long      lResult;  char      szBuf[MAX_BUF];  char      szIndex0[MAX_BUF];  char      szCounter[MAX_BUF];  char      szFileIdiGetArchives[MAX_BUF];  char      szSComponent[MAX_BUF];  char      szSFile[MAX_BUF];  RetrieveRedirectFile();  lstrcpy(szFileIdiGetArchives, szTempDir);  AppendBackSlash(szFileIdiGetArchives, sizeof(szFileIdiGetArchives));  lstrcat(szFileIdiGetArchives, FILE_IDI_GETARCHIVES);  dwIndex0  = 0;  dwCounter = 0;  itoa(dwIndex0,  szIndex0,  10);  itoa(dwCounter, szCounter, 10);  siCObject = SiCNodeGetObject(dwIndex0, TRUE, AC_ALL);  while(siCObject)  {    if(siCObject->dwAttributes & SIC_SELECTED)    {      /* only download jars if not already in the local machine */      if(LocateJar(siCObject, NULL, 0) == FALSE)      {        lstrcpy(szSComponent, "Component");        lstrcat(szSComponent, szIndex0);        lstrcpy(szSFile, "File");        lstrcat(szSFile, szCounter);        if((lResult = AddArchiveToIdiFile(siCObject, szSComponent, szSFile, szFileIdiGetArchives)) != 0)          return(lResult);        ++dwCounter;        itoa(dwCounter, szCounter, 10);      }    }    ++dwIndex0;    itoa(dwIndex0, szIndex0, 10);    siCObject = SiCNodeGetObject(dwIndex0, TRUE, AC_ALL);  }  /* the existance of the getarchives.idi file determines if there are     any jar files needed to be downloaded */  if(FileExists(szFileIdiGetArchives))  {    DecryptString(szBuf, siSDObject.szXpcomDir);    lstrcpy(siSDObject.szXpcomDir, szBuf);    WritePrivateProfileString("Netscape Install", "core_file",        siSDObject.szXpcomFile,       szFileIdiGetArchives);    WritePrivateProfileString("Netscape Install", "core_dir",         siSDObject.szXpcomDir,        szFileIdiGetArchives);    WritePrivateProfileString("Netscape Install", "no_ads",           siSDObject.szNoAds,           szFileIdiGetArchives);    WritePrivateProfileString("Netscape Install", "silent",           siSDObject.szSilent,          szFileIdiGetArchives);    WritePrivateProfileString("Netscape Install", "execution",        siSDObject.szExecution,       szFileIdiGetArchives);    WritePrivateProfileString("Netscape Install", "confirm_install",  siSDObject.szConfirmInstall,  szFileIdiGetArchives);    WritePrivateProfileString("Netscape Install", "extract_msg",      siSDObject.szExtractMsg,      szFileIdiGetArchives);    WritePrivateProfileString("Execution",        "exe",              siSDObject.szExe,             szFileIdiGetArchives);    WritePrivateProfileString("Execution",        "exe_param",        siSDObject.szExeParam,        szFileIdiGetArchives);    /* proxy support */    if((*sgProduct.szProxyServer != '\0') && (*sgProduct.szProxyPort != '\0'))    {      WritePrivateProfileString("Proxy", "server", sgProduct.szProxyServer, szFileIdiGetArchives);      WritePrivateProfileString("Proxy", "port",   sgProduct.szProxyPort,   szFileIdiGetArchives);    }    if((lResult = SdArchives(szFileIdiGetArchives, szTempDir)) != 0)      return(lResult);  }  return(0);}