From: Luke Howard Date: Tue, 21 Jan 2003 14:08:58 +0000 (+0000) Subject: Added OpenLDAP-specific SLAPI for getting entry ID X-Git-Tag: NO_SLAP_OP_BLOCKS~561 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=8de6186e54e07f3f6eabbb1c973c3d5d6f4e7a82;p=openldap Added OpenLDAP-specific SLAPI for getting entry ID --- diff --git a/servers/slapd/slapi/slapi_utils.c b/servers/slapd/slapi/slapi_utils.c index eefea53341..1803dabe40 100644 --- a/servers/slapd/slapi/slapi_utils.c +++ b/servers/slapd/slapi/slapi_utils.c @@ -132,6 +132,16 @@ slapi_entry_get_dn( Slapi_Entry *e ) #endif /* !defined(LDAP_SLAPI) */ } +int +slapi_x_entry_get_id( Slapi_Entry *e ) +{ +#if defined(LDAP_SLAPI) + return e->e_id; +#else + return NOID; +#endif /* !defined(LDAP_SLAPI) */ +} + void slapi_entry_set_dn( Slapi_Entry *e, diff --git a/servers/slapd/slapi/slapi_utils.h b/servers/slapd/slapi/slapi_utils.h index ee7be4b62d..0b97dfb683 100644 --- a/servers/slapd/slapi/slapi_utils.h +++ b/servers/slapd/slapi/slapi_utils.h @@ -49,6 +49,7 @@ int slapi_entry_attr_merge( Slapi_Entry *e, char *type, struct berval **vals ); int slapi_entry_attr_find( Slapi_Entry *e, char *type, Slapi_Attr **attr ); int slapi_entry_attr_delete( Slapi_Entry *e, char *type ); char *slapi_entry_get_dn( Slapi_Entry *e ); +int slapi_x_entry_get_id( Slapi_Entry *e ); void slapi_entry_set_dn( Slapi_Entry *e, char *dn ); Slapi_Entry *slapi_entry_dup( Slapi_Entry *e ); Slapi_Entry *slapi_entry_alloc();