]> git.sur5r.net Git - openldap/blobdiff - contrib/ldapc++/src/LDAPDeleteRequest.cpp
Merge branch 'mdb.master' of /home/hyc/OD/mdb
[openldap] / contrib / ldapc++ / src / LDAPDeleteRequest.cpp
index bad6adcdfe5f45bac61041f9eaaf4e6c20f1c17d..4ccb39944a4d35f9254b0af9e4ff9beb04972448 100644 (file)
@@ -1,5 +1,6 @@
+// $OpenLDAP$
 /*
- * Copyright 2000, OpenLDAP Foundation, All Rights Reserved.
+ * Copyright 2000-2011 The OpenLDAP Foundation, All Rights Reserved.
  * COPYING RESTRICTIONS APPLY, see COPYRIGHT file
  */
 
@@ -35,9 +36,6 @@ LDAPDeleteRequest::LDAPDeleteRequest(const string& dn,
 LDAPDeleteRequest::~LDAPDeleteRequest(){
     DEBUG(LDAP_DEBUG_DESTROY,
           "LDAPDeleteRequest::~LDAPDeleteRequest()" << endl);
-    // TODO -- flush the entire cache here?  or does this invalidate
-    // cached searches that may have found the deleted entry.
-    m_connection->uncache_entry(m_dn);
 }
 
 LDAPMessageQueue* LDAPDeleteRequest::sendRequest(){
@@ -47,8 +45,8 @@ LDAPMessageQueue* LDAPDeleteRequest::sendRequest(){
     LDAPControl** tmpClCtrls=m_cons->getClCtrlsArray();
     int err=ldap_delete_ext(m_connection->getSessionHandle(),m_dn.c_str(), 
             tmpSrvCtrls, tmpClCtrls ,&msgID);
-    ldap_controls_free(tmpSrvCtrls);
-    ldap_controls_free(tmpClCtrls);
+    LDAPControlSet::freeLDAPControlArray(tmpSrvCtrls);
+    LDAPControlSet::freeLDAPControlArray(tmpClCtrls);
     if(err != LDAP_SUCCESS){
         throw LDAPException(err);
     }else{