44.4. slapi_vattr_value_compare()
This function compares attribute type and name in a given entry. There is no need to call slapi_vattr_values_free() after calling this function.
#include "slapi-plugin.h" int slapi_vattr_value_compare( Slapi_Entry *e, char *type, Slapi_Value *test_this, int *result, int flags);
This function takes the following parameters:
|
e
| Entry to be compared. |
|
type
| Attribute type name. |
|
test_this
| Value to be tested. |
|
result
| 0 if the compare is true, 1 if the compare is false. |
|
flags
| Not used. You should pass 0 for this parameter. |
This function returns 1 for success, in which case result contains the result of the comparison. Otherwise, this function returns 0 and one of the following:
SLAPI_VIRTUALATTRS_LOOP_DETECTED(failed to evaluate a vattr).SLAPI_VIRTUAL_NOT_FOUND(type not recognized by any vattr and not a real attr in entry).ENOMEM(memory error).

Where did the comment section go?
Red Hat's documentation publication system recently went through an upgrade to enable speedier, more mobile-friendly content. We decided to re-evaluate our commenting platform to ensure that it meets your expectations and serves as an optimal feedback mechanism. During this redesign, we invite your input on providing feedback on Red Hat documentation via the discussion platform.