14.9. send_ldap_referral_fn_ptr_t
slapi_send_ldap_result() function is called.
#include "slapi-plugin.h" typedef int (*send_ldap_referral_fn_ptr_t)( Slapi_PBlock *pb, Slapi_Entry *e, struct berval **refs, struct berval ***urls);
This function takes the following parameters:
| pb | Parameter block. |
| e | Pointer to the Slapi_Entry structure representing the entry with which you are working. |
| refs | Pointer to the NULL-terminated array of berval structures containing the LDAPv3 referrals (search result references) found in the entry. |
| urls | Pointer to the array of berval structures used to collect LDAP referrals for LDAPv2 clients. |
This function returns 0 if successful, or -1 if an error occurs.
The slapi_send_ldap_result() function is responsible for sending LDAPv3 referrals (search result references) back to the client. You can replace the function that sends LDAPv3 referrals to the client with your own function. To do this:
- Write a function with the prototype specified by
send_ldap_result_fn_ptr_t. - In your plug-in initialization function, register your function by setting the SLAPI_PLUGIN_PRE_REFERRAL_FN parameter in the parameter block to the name of your function if you are using the pre-operation plug-in. If you are using the post-operation plug-in, register your function by setting the SLAPI_PLUGIN_POST_REFERRAL_FN parameter in the parameter block to the name of your function.
send_result()

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.