Terraria v1.4.4.9
Terraria source code documentation
Loading...
Searching...
No Matches

◆ GetPortCommandLine()

string System.Net.FtpControlStream.GetPortCommandLine ( FtpWebRequest request)
inlineprivate

Definition at line 831 of file FtpControlStream.cs.

832 {
833 try
834 {
835 IPEndPoint iPEndPoint = (IPEndPoint)_dataSocket.LocalEndPoint;
836 if (base.ServerAddress.AddressFamily == AddressFamily.InterNetwork || base.ServerAddress.IsIPv4MappedToIPv6)
837 {
838 return FormatAddress(iPEndPoint.Address, iPEndPoint.Port);
839 }
840 if (base.ServerAddress.AddressFamily == AddressFamily.InterNetworkV6)
841 {
842 return FormatAddressV6(iPEndPoint.Address, iPEndPoint.Port);
843 }
844 throw new System.Net.InternalException();
845 }
846 catch (Exception innerException)
847 {
849 }
850 }
Exception GenerateException(string message, WebExceptionStatus status, Exception innerException)
string FormatAddressV6(IPAddress address, int port)
string FormatAddress(IPAddress address, int Port)
unsafe? EndPoint LocalEndPoint
Definition Socket.cs:615
static string net_ftp_protocolerror
Definition SR.cs:104
Definition SR.cs:7

References System.Net.FtpControlStream._dataSocket, System.Net.FtpControlStream.FormatAddress(), System.Net.FtpControlStream.FormatAddressV6(), System.Net.CommandStream.GenerateException(), System.Net.Sockets.Socket.LocalEndPoint, and System.SR.net_ftp_protocolerror.

Referenced by System.Net.FtpControlStream.BuildCommandsList().