Author: borisk
Date: 2005-11-06 04:20:55 -0500 (Sun, 06 Nov 2005)
New Revision: 52618

Modified:
   trunk/mcs/class/System.DirectoryServices/System.DirectoryServices/ChangeLog
   
trunk/mcs/class/System.DirectoryServices/System.DirectoryServices/DirectoryEntry.cs
Log:
Fixes for RefreshCache().

Modified: 
trunk/mcs/class/System.DirectoryServices/System.DirectoryServices/ChangeLog
===================================================================
--- trunk/mcs/class/System.DirectoryServices/System.DirectoryServices/ChangeLog 
2005-11-06 01:49:55 UTC (rev 52617)
+++ trunk/mcs/class/System.DirectoryServices/System.DirectoryServices/ChangeLog 
2005-11-06 09:20:55 UTC (rev 52618)
@@ -1,3 +1,11 @@
+2005-06-11  Boris Kirzner <[EMAIL PROTECTED]>
+       * DirectoryEntry.cs: fixes for RefreshCache()
+               -Property names should be sent to server if only particular 
properties
+               need to be updated.
+               -Refreshing all the properties should work with separate list,
+               so the original properties values are not damaged if the refresh
+               fails for some reason.
+
 2005-30-10  Boris Kirzner <[EMAIL PROTECTED]>
        * DirectoryEntries.cs: fix for null base dn.
        * DirectorySearcher.cs: use server root authentication type for binding.

Modified: 
trunk/mcs/class/System.DirectoryServices/System.DirectoryServices/DirectoryEntry.cs
===================================================================
--- 
trunk/mcs/class/System.DirectoryServices/System.DirectoryServices/DirectoryEntry.cs
 2005-11-06 01:49:55 UTC (rev 52617)
+++ 
trunk/mcs/class/System.DirectoryServices/System.DirectoryServices/DirectoryEntry.cs
 2005-11-06 09:20:55 UTC (rev 52618)
@@ -664,7 +664,7 @@
                {
                        _inPropertiesLoading = true;
                        try     {
-                               LdapSearchResults lsc=conn.Search 
(Fdn,LdapConnection.SCOPE_BASE,"objectClass=*",null,false);
+                               LdapSearchResults lsc=conn.Search 
(Fdn,LdapConnection.SCOPE_BASE,"objectClass=*",propertyNames,false);
                                if (lsc.hasMore ()) {
                                        LdapEntry nextEntry = lsc.next ();
                                        string [] lowcasePropertyNames = null;
@@ -1060,7 +1060,9 @@
                public void RefreshCache ()
                {
                        // note that GetProperties must be called with false, 
elswere infinite loop will be caused
-                       LoadProperties(GetProperties(false),null);
+                       PropertyCollection properties = new PropertyCollection 
();
+                       LoadProperties(properties, null);
+                       SetProperties (properties);
                }
 
                /// <summary>

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

Reply via email to