HP-UX Directory Server 8.1 plug-in reference

Table Of Contents
See also “slapi_mods2entry()”
33.2 slapi_mod_add_value()
Description Adds a copy of a given attribute to the Slapi_Mod structure.
Syntax
#include "slapi-plugin.h"
void slapi_mod_add_value(Slapi_Mod *smod, const struct berval *val);
Parameters This function takes the following parameters:
Pointer to an initialized Slapi_Mod.smod
Pointer to a berval representing the attribute value.val
33.3 slapi_mod_done()
Description This function frees the internals of a Slapi_Mod, leaving it in the uninitialized
state.
Syntax
#include "slapi-plugin.h"
void slapi_mod_done(Slapi_Mod *mod);
Parameters This function takes the following parameter:
Pointer to a Slapi_Mod.mod
Memory concerns Use this function on a stack-allocated Slapi_Mod when you have finished
with it or want to reuse it.
See also
“slapi_mod_init()”
“slapi_mod_init_byval()”
“slapi_mod_init_byref()”
“slapi_mod_init_passin()”
33.4 slapi_mod_dump()
Description This function uses the LDAP_DEBUG_ANY log level to dump the contents of an
LDAPMod to the server log for debugging.
Syntax
#include "slapi-plugin.h"
void slapi_mod_dump(LDAPMod *mod, int n);
Parameters This function takes the following parameters:
Pointer to an LDAPMod.mod
Numeric label that will be included in the log.
n
33.5 slapi_mod_free()
Description This function frees a Slapi_Mod structure that was allocated by “slapi_mod_new()”.
Syntax
#include "slapi-plugin.h"
void slapi_mod_free(Slapi_Mod **smod);
33.2 slapi_mod_add_value() 267