Forráskód Böngészése

Use IndexOf (char)

svn path=/trunk/mcs/; revision=122121
Gonzalo Paniagua Javier 17 éve
szülő
commit
55bbc22620

+ 2 - 2
mcs/class/System.Data/System.Data.SqlClient/SqlConnection.cs

@@ -579,11 +579,11 @@ namespace System.Data.SqlClient
 			bool success = true;
 
 			int idx = 0;
-			if ((idx = theDataSource.IndexOf (",")) > -1) {
+			if ((idx = theDataSource.IndexOf (',')) > -1) {
 				theServerName = theDataSource.Substring (0, idx);
 				string p = theDataSource.Substring (idx + 1);
 				thePort = Int32.Parse (p);
-			} else if ((idx = theDataSource.IndexOf ("\\")) > -1) {
+			} else if ((idx = theDataSource.IndexOf ('\\')) > -1) {
 				theServerName = theDataSource.Substring (0, idx);
 				theInstanceName = theDataSource.Substring (idx + 1);