예제 #1
0
        // Probably move some code of command connection here
        private void ResolveHost()
        {
            CheckIfAborted();
            hostEntry = GetServicePoint().HostEntry;

            if (hostEntry == null)
            {
                ftpResponse.UpdateStatus(new FtpStatus(FtpStatusCode.ActionAbortedLocalProcessingError, "Cannot resolve server name"));
                throw new WebException("The remote server name could not be resolved: " + requestUri, null, WebExceptionStatus.NameResolutionFailure, ftpResponse);
            }
        }