Pierangelo Masarati wrote:
Howard Chu wrote:
I was thinking about how both pagedresults and server-side sorting
could be accomplished using overlays, and the idea is simple enough.
But one of the more awkward aspects of adding new controls is
plugging them into the Operation structure so they can be easily
referenced by other code. I recall how OpenSSL handles various
OID-based entities - it has its own internal registry and assigns
small integers (NIDs) for each one. I think we need a similar
mechanism for slapd.
Specifically, the register_supported_control function should return
the index of the control in slapd's internal table. The Operation
structure should have an array
void **o_controls
.. or void *o_controls[NID_MAX]; ?
I guess that would be OK. Any reason you prefer that over dynamically
sizing the array? (I prefer to avoid hard limits, and I don't see a
compelling need to limit this one.)