gbStartTickCounter = TRUE;
int DownloadViaProxy(char *szUrl, char *szProxyServer, char *szProxyPort, char *szProxyUser, char *szProxyPasswd){  int  rv;  char *file = NULL;  rv = nsHTTPConn::OK;  if((!szUrl) || (*szUrl == '\0'))    return nsHTTPConn::E_PARAM;  if(connHTTP == NULL)  {    rv = DownloadViaProxyOpen(szUrl,                              szProxyServer,                              szProxyPort,                              szProxyUser,                              szProxyPasswd);    if(rv != nsHTTPConn::OK)    {      DownloadViaProxyClose();      return(rv);    }  }  if(connHTTP == NULL)  {    char szBuf[MAX_BUF_TINY];    GetPrivateProfileString("Strings", "Error Out Of Memory", "", szBuf, sizeof(szBuf), szFileIniConfig);    PrintError(szBuf, ERROR_CODE_HIDE);    return(WIZ_OUT_OF_MEMORY);  }  if(strrchr(szUrl, '/') != (szUrl + strlen(szUrl)))    file = strrchr(szUrl, '/') + 1; // set to leaf name  rv = connHTTP->Get(ProgressCB, file); // use leaf from URL  DownloadViaProxyClose();  return(rv);}