Wed Sep 11 15:26:34 CEST 2002 Paolo Molaro <lupus@ximian.com>
[mono.git] / mcs / class / corlib / System / Buffer.cs
index 16a48b665924480fc36f65836f1da8b7d6dd7bf3..ac0209fbd3f517c0560528f4834e5a6db07089a3 100755 (executable)
@@ -31,14 +31,14 @@ namespace System {
 
                public static byte GetByte (Array array, int index) {
                        if (index < 0 || index >= ByteLength (array))
-                               throw new ArgumentException ("Index was out of range. Must be non-negative and less than the size of the collection.");
+                               throw new ArgumentOutOfRangeException ("Index was out of range. Must be non-negative and less than the size of the collection.");
 
                        return GetByteInternal (array, index);
                }
 
                public static void SetByte (Array array, int index, byte value) {
                        if (index < 0 || index >= ByteLength (array))
-                               throw new ArgumentException ("Index was out of range. Must be non-negative and less than the size of the collection.");
+                               throw new ArgumentOutOfRangeException ("Index was out of range. Must be non-negative and less than the size of the collection.");
 
                        SetByteInternal (array, index, value);
                }