Author: spouliot
Date: 2005-10-28 10:55:30 -0400 (Fri, 28 Oct 2005)
New Revision: 52326
Modified:
trunk/mcs/class/corlib/System.Runtime.InteropServices/ChangeLog
trunk/mcs/class/corlib/System.Runtime.InteropServices/Marshal.cs
Log:
2005-10-28 Sebastien Pouliot <[EMAIL PROTECTED]>
* Marshal.cs: Added null check in SecureStringTo* methods and make
them throw a NotSupportedException otherwise (as existing code must
deal with this anyway). Fixed Uni -> Unicode method name changes.
Modified: trunk/mcs/class/corlib/System.Runtime.InteropServices/ChangeLog
===================================================================
--- trunk/mcs/class/corlib/System.Runtime.InteropServices/ChangeLog
2005-10-28 14:48:03 UTC (rev 52325)
+++ trunk/mcs/class/corlib/System.Runtime.InteropServices/ChangeLog
2005-10-28 14:55:30 UTC (rev 52326)
@@ -1,3 +1,9 @@
+2005-10-28 Sebastien Pouliot <[EMAIL PROTECTED]>
+
+ * Marshal.cs: Added null check in SecureStringTo* methods and make
+ them throw a NotSupportedException otherwise (as existing code must
+ deal with this anyway). Fixed Uni -> Unicode method name changes.
+
2005-09-25 Sebastien Pouliot <[EMAIL PROTECTED]>
* UCOMIBindCtx.cs, UCOMIConnectionPoint.cs,
Modified: trunk/mcs/class/corlib/System.Runtime.InteropServices/Marshal.cs
===================================================================
--- trunk/mcs/class/corlib/System.Runtime.InteropServices/Marshal.cs
2005-10-28 14:48:03 UTC (rev 52325)
+++ trunk/mcs/class/corlib/System.Runtime.InteropServices/Marshal.cs
2005-10-28 14:55:30 UTC (rev 52326)
@@ -177,27 +177,32 @@
#if NET_2_0
[MonoTODO]
- public static void ZeroFreeBSTR (IntPtr ptr) {
+ public static void ZeroFreeBSTR (IntPtr ptr)
+ {
throw new NotImplementedException ();
}
[MonoTODO]
- public static void ZeroFreeCoTaskMemAnsi (IntPtr ptr) {
+ public static void ZeroFreeCoTaskMemAnsi (IntPtr ptr)
+ {
throw new NotImplementedException ();
}
[MonoTODO]
- public static void ZeroFreeCoTaskMemUni (IntPtr ptr) {
+ public static void ZeroFreeCoTaskMemUnicode (IntPtr ptr)
+ {
throw new NotImplementedException ();
}
[MonoTODO]
- public static void ZeroFreeGlobalAllocAnsi (IntPtr hglobal) {
+ public static void ZeroFreeGlobalAllocAnsi (IntPtr hglobal)
+ {
throw new NotImplementedException ();
}
[MonoTODO]
- public static void ZeroFreeGlobalAllocUni (IntPtr hglobal) {
+ public static void ZeroFreeGlobalAllocUnicode (IntPtr hglobal)
+ {
throw new NotImplementedException ();
}
#endif
@@ -633,28 +638,43 @@
#if NET_2_0
[MonoTODO]
- public static IntPtr SecureStringToBSTR (SecureString s) {
- throw new NotImplementedException ();
+ public static IntPtr SecureStringToBSTR (SecureString s)
+ {
+ if (s == null)
+ throw new ArgumentNullException ("s");
+ throw new NotSupportedException ();
}
[MonoTODO]
- public static IntPtr SecureStringToCoTaskMemAnsi (SecureString
s) {
- throw new NotImplementedException ();
+ public static IntPtr SecureStringToCoTaskMemAnsi (SecureString
s)
+ {
+ if (s == null)
+ throw new ArgumentNullException ("s");
+ throw new NotSupportedException ();
}
[MonoTODO]
- public static IntPtr SecureStringToCoTaskMemUni (SecureString
s) {
- throw new NotImplementedException ();
+ public static IntPtr SecureStringToCoTaskMemUnicode
(SecureString s)
+ {
+ if (s == null)
+ throw new ArgumentNullException ("s");
+ throw new NotSupportedException ();
}
[MonoTODO]
- public static IntPtr SecureStringToGlobalAllocAnsi
(SecureString s) {
- throw new NotImplementedException ();
+ public static IntPtr SecureStringToGlobalAllocAnsi
(SecureString s)
+ {
+ if (s == null)
+ throw new ArgumentNullException ("s");
+ throw new NotSupportedException ();
}
[MonoTODO]
- public static IntPtr SecureStringToGlobalAllocUni (SecureString
s) {
- throw new NotImplementedException ();
+ public static IntPtr SecureStringToGlobalAllocUnicode
(SecureString s)
+ {
+ if (s == null)
+ throw new ArgumentNullException ("s");
+ throw new NotSupportedException ();
}
#endif
_______________________________________________
Mono-patches maillist - [email protected]
http://lists.ximian.com/mailman/listinfo/mono-patches