Browse Source

2002-07-22 Gonzalo Paniagua Javier <[email protected]>

	* Int32.cs:
	* Int64.cs:
	* UInt32.cs:
	* UInt64.cs: fixed bug #28050. May be a MS bug?

svn path=/trunk/mcs/; revision=6023
Gonzalo Paniagua Javier 23 years ago
parent
commit
5cea83b9b5

+ 6 - 0
mcs/class/corlib/System/ChangeLog

@@ -1,3 +1,9 @@
+2002-07-22  Gonzalo Paniagua Javier <[email protected]>
+
+	* Int32.cs:
+	* Int64.cs:
+	* UInt32.cs:
+	* UInt64.cs: fixed bug #28050. May be a MS bug?
 
 Thu Jul 18 14:47:03 CEST 2002 Paolo Molaro <[email protected]>
 

+ 1 - 1
mcs/class/corlib/System/Int32.cs

@@ -378,7 +378,7 @@ namespace System {
 					pos = JumpOverWhite (pos, s, false);
 			}
 
-			if (pos < s.Length)
+			if (pos < s.Length && s [pos] != '\u0000')
 				throw new FormatException ("Input string was not in the correct format.");
 
 			

+ 1 - 1
mcs/class/corlib/System/Int64.cs

@@ -307,7 +307,7 @@ namespace System {
 					pos = Int32.JumpOverWhite (pos, s, false);
 			}
 
-			if (pos < s.Length)
+			if (pos < s.Length && s [pos] != '\u0000')
 				throw new FormatException ("Input string was not in the correct format: Did not parse entire string. pos = " 
 										+ pos + " s.Length = " + s.Length);
 

+ 1 - 1
mcs/class/corlib/System/UInt32.cs

@@ -306,7 +306,7 @@ namespace System {
 					pos = Int32.JumpOverWhite (pos, s, false);
 			}
 
-			if (pos < s.Length)
+			if (pos < s.Length && s [pos] != '\u0000')
 				throw new FormatException ("Input string was not in the correct format.");
 
 			if (negative)

+ 1 - 1
mcs/class/corlib/System/UInt64.cs

@@ -251,7 +251,7 @@ namespace System {
 					pos = Int32.JumpOverWhite (pos, s, false);
 			}
 
-			if (pos < s.Length)
+			if (pos < s.Length && s [pos] != '\u0000')
 				throw new FormatException ("Input string was not in the correct format.");
 
 			if (negative)