]> git.sur5r.net Git - openldap/commitdiff
misc cleanup
authorJong Hyuk Choi <jongchoi@openldap.org>
Mon, 1 Dec 2003 17:56:36 +0000 (17:56 +0000)
committerJong Hyuk Choi <jongchoi@openldap.org>
Mon, 1 Dec 2003 17:56:36 +0000 (17:56 +0000)
servers/slapd/add.c
servers/slapd/back-meta/cache-merge.c
servers/slapd/proto-slap.h
servers/slapd/tools/mimic.c

index 7824ca212b01649a61b7fbcb2cba2fad39e29a1c..b951f406cec5ea40c2b26473078ee4474449d7cc 100644 (file)
@@ -588,7 +588,8 @@ int
 slap_entry2mods(
        Entry *e,
        Modifications **mods,
-       const char **text
+       const char **text,
+       char *textbuf, size_t textlen )
 )
 {
        Modifications   *modhead = NULL;
@@ -596,7 +597,9 @@ slap_entry2mods(
        Modifications   **modtail = &modhead;
        Attribute               *a_new;
        AttributeDescription    *a_new_desc;
-       int                             i, count, rc;
+       int                             i, count;
+
+       *text = textbuf;
 
        a_new = e->e_attrs;
 
index d2ad3338d8d24fd2b9916dabe534121eac6a2e12..e6cce64bc883a44d7be79b48aa9eff9f76f585b7 100644 (file)
@@ -112,6 +112,8 @@ merge_entry(
        BerVarray               value_array; 
        Attribute               *uuid_attr, *attr;
        Entry                   *e;
+       char                    textbuf[SLAP_TEXT_BUFLEN];
+       size_t                  textlen = sizeof(textbuf);
 
        SlapReply sreply = {REP_RESULT};
 
@@ -176,7 +178,7 @@ merge_entry(
 
        if ( rc != LDAP_SUCCESS ) {
                if ( rc == LDAP_ALREADY_EXISTS ) {
-                       slap_entry2mods( e, &modlist, &text );
+                       slap_entry2mods( e, &modlist, &text, textbuf, textlen );
                        op_tmp.o_tag = LDAP_REQ_MODIFY;
                        op_tmp.orm_modlist = modlist;
                        op_tmp.o_req_dn = e->e_name;
index 59712f87dcf2702c464d28cb72bbc4741dc104b8..fe119359ad04375e77da2363ee72d168911d8b36 100644 (file)
@@ -118,7 +118,8 @@ LDAP_SLAPD_F (int) slap_mods2entry LDAP_P(( Modifications *mods, Entry **e,
        int repl_user, int dup, const char **text, char *textbuf, size_t textlen ));
 
 LDAP_SLAPD_F (int) slap_entry2mods LDAP_P(( Entry *e,
-                                               Modifications **mods, const char **text ));
+                                               Modifications **mods, const char **text,
+                                               char *textbuf, size_t textlen ));
 
 /*
  * at.c
index b3eaa6fe8c5228ee45cd6623a82168170d89de84..387eef2988dd5b686fd7fd5da7fe56522390df79 100644 (file)
@@ -280,7 +280,8 @@ int root_dse_info( Connection *conn, Entry **entry, const char **text )
        return -1;
 }
 
-int slap_entry2mods( Entry *e, Modifications **mods, const char **text )
+int slap_entry2mods( Entry *e, Modifications **mods, const char **text,
+                                        char *textbuf, size_t textlen )
 {
        return -1;
 }