ソースを参照

Check that the default from is not empty

	This should fix a bunch of tests failing since MailAddress parsing was
	fixed.
Gonzalo Paniagua Javier 15 年 前
コミット
b353b9cc84
1 ファイル変更1 行追加1 行削除
  1. 1 1
      mcs/class/System/System.Net.Mail/SmtpClient.cs

+ 1 - 1
mcs/class/System/System.Net.Mail/SmtpClient.cs

@@ -135,7 +135,7 @@ namespace System.Net.Mail {
 					Credentials = new CCredentialsByHost (cfg.Network.UserName, password);
 				}
 
-				if (cfg.From != null)
+				if (!String.IsNullOrEmpty (cfg.From))
 					defaultFrom = new MailAddress (cfg.From);
 			}
 #else