24.4. slapi_entry_add_string()

Description

This function adds a string value to the existing attribute values in an entry. If the specified attribute does not exist in the entry, the attribute is created with the string value specified. The function doesn't check for duplicate values; it does not check if the string value being added is already there.

Syntax

#include "slapi-plugin.h"
int slapi_entry_add_string (Slapi_Entry *e, const char *type, const char *value);

Parameters

This function takes the following parameters:

e
Entry to which you want to add a string value.
type
Attribute to which you want to add a string value.
value
String value you want to add.
Returns

This function returns 0 when successful; any other value returned signals failure.

Memory Concerns

This routine makes a copy of the parameter value. value can be NULL.