Author: miguel
Date: 2007-11-01 12:01:17 -0500 (Thu, 01 Nov 2007)
New Revision: 88666

Modified:
   trunk/mono/mono/metadata/ChangeLog
   trunk/mono/mono/metadata/icall.c
Log:
Reverted patch as it introduced many regressions, see 
https://bugzilla.novell.com/show_bug.cgi?id=333740#c4

Modified: trunk/mono/mono/metadata/ChangeLog
===================================================================
--- trunk/mono/mono/metadata/ChangeLog  2007-11-01 17:00:24 UTC (rev 88665)
+++ trunk/mono/mono/metadata/ChangeLog  2007-11-01 17:01:17 UTC (rev 88666)
@@ -10,15 +10,6 @@
        * reflection.c (mono_custom_attrs_from_class): Add support for dynamic 
inflated 
        classes.
 
-2007-10-15  Jonathan Chambers <[EMAIL PROTECTED]>
-
-       * icall.c: Use GetEnvironmentStrings on windows
-       so we are using the same environment block as 
-       GetEnvironmentVariable/SetEnvironmentVariable. Fixes
-       #333740.
-       
-       Code is contributed under MIT/X11 license.
-
 2007-10-30  Atsushi Enomoto  <[EMAIL PROTECTED]>
 
        * culture-info-table.h : regenerated.

Modified: trunk/mono/mono/metadata/icall.c
===================================================================
--- trunk/mono/mono/metadata/icall.c    2007-11-01 17:00:24 UTC (rev 88665)
+++ trunk/mono/mono/metadata/icall.c    2007-11-01 17:01:17 UTC (rev 88666)
@@ -5883,58 +5883,9 @@
 static MonoArray *
 ves_icall_System_Environment_GetEnvironmentVariableNames (void)
 {
-#ifdef PLATFORM_WIN32
        MonoArray *names;
        MonoDomain *domain;
        MonoString *str;
-       WCHAR* env_strings;
-       WCHAR* env_string;
-       WCHAR* equal_str;
-       int n = 0;
-
-       env_strings = GetEnvironmentStrings();
-
-       if (env_strings) {
-               env_string = env_strings;
-               while (*env_string != '\0') {
-               /* weird case that MS seems to skip */
-                       if (*env_string != '=')
-                               n++;
-                       while (*env_string != '\0')
-                               env_string++;
-                       env_string++;
-               }
-       }
-
-       domain = mono_domain_get ();
-       names = mono_array_new (domain, mono_defaults.string_class, n);
-
-       if (env_strings) {
-               n = 0;
-               env_string = env_strings;
-               while (*env_string != '\0') {
-                       /* weird case that MS seems to skip */
-                       if (*env_string != '=') {
-                               equal_str = wcschr(env_string, '=');
-                               g_assert(equal_str);
-                               str = mono_string_new_utf16 (domain, 
env_string, equal_str-env_string);
-                               mono_array_setref (names, n, str);
-                       }
-                       while (*env_string != '\0')
-                               env_string++;
-                       env_string++;
-                       n++;
-               }
-
-               FreeEnvironmentStrings (env_strings);
-       }
-
-       return names;
-
-#else
-       MonoArray *names;
-       MonoDomain *domain;
-       MonoString *str;
        gchar **e, **parts;
        int n;
 
@@ -5961,7 +5912,6 @@
        }
 
        return names;
-#endif
 }
 
 /*

_______________________________________________
Mono-patches maillist  -  [email protected]
http://lists.ximian.com/mailman/listinfo/mono-patches

Reply via email to