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

◆ HandshakeCallback()

static void System.Net.Mail.SmtpConnection.ConnectAndHandshakeAsyncResult.HandshakeCallback ( IAsyncResult result)
inlinestaticprivate

Definition at line 157 of file SmtpConnection.cs.

158 {
159 if (result.CompletedSynchronously)
160 {
161 return;
162 }
163 ConnectAndHandshakeAsyncResult connectAndHandshakeAsyncResult = (ConnectAndHandshakeAsyncResult)result.AsyncState;
164 try
165 {
166 try
167 {
168 LineInfo lineInfo = connectAndHandshakeAsyncResult._connection.Reader.CurrentReader.EndReadLine(result);
169 if (lineInfo.StatusCode != SmtpStatusCode.ServiceReady)
170 {
171 connectAndHandshakeAsyncResult.InvokeCallback(new SmtpException(lineInfo.StatusCode, lineInfo.Line, serverResponse: true));
172 }
173 else if (connectAndHandshakeAsyncResult.SendEHello())
174 {
175 }
176 }
177 catch (SmtpException)
178 {
179 if (connectAndHandshakeAsyncResult.SendHello())
180 {
181 }
182 }
183 }
184 catch (Exception result2)
185 {
186 connectAndHandshakeAsyncResult.InvokeCallback(result2);
187 }
188 }
ConnectAndHandshakeAsyncResult(SmtpConnection connection, string host, int port, System.Net.ContextAwareResult outerResult, AsyncCallback callback, object state)

References System.Net.Mail.SmtpConnection.ConnectAndHandshakeAsyncResult.ConnectAndHandshakeAsyncResult(), System.Net.Mail.SmtpConnection.ConnectAndHandshakeAsyncResult._connection, System.IAsyncResult.AsyncState, System.IAsyncResult.CompletedSynchronously, System.Net.Mail.SmtpReplyReaderFactory.CurrentReader, System.Net.Mail.SmtpReplyReader.EndReadLine(), System.Net.LazyAsyncResult.InvokeCallback(), System.Net.Mail.LineInfo.Line, System.Net.Mail.SmtpConnection.Reader, System.Net.Mail.SmtpConnection.ConnectAndHandshakeAsyncResult.SendEHello(), System.Net.Mail.SmtpConnection.ConnectAndHandshakeAsyncResult.SendHello(), and System.Net.Mail.LineInfo.StatusCode.