* GCHandle.cs: Clearer ArgumentException text in the case of a
null-valued IntPtr argument.
svn path=/trunk/mcs/; revision=42428
+2005-03-31 Alp Toker <alp@atoker.com>
+
+ * GCHandle.cs: Clearer ArgumentException text in the case of a
+ null-valued IntPtr argument.
+
2005-03-04 Kazuki Oikawa <kazuki@panicode.com>
* _Exception.cs
public static explicit operator GCHandle(IntPtr value)
{
+ if (value == IntPtr.Zero)
+ throw new ArgumentException ("GCHandle value cannot be zero");
if (!CheckCurrentDomain ((int)value))
throw new ArgumentException ("GCHandle value belongs to a different domain");
return new GCHandle (value);