Segfault when disconnect callback is null
The documentation of rist_auth_handler_set()
specifies:
disconn_cb : A pointer to the function that will be called when a new peer is marked as dead (NULL function pointer is valid)
On listener side, I call rist_auth_handler_set()
with the address of a connection callback but a null pointer as disconnection callback (I am only interested in filtering connections). This is explicitly allowed in the documentation of the function. When the peer disconnects, the listener crashes on segfault.
If I specify the non-null address of a disconnection callback, the segfault no longer occurs and the callback is invoked.
I haven't tested the opposite, null connection-callback and non-null disconnection callback.