void nopoll_ctx_set_on_msg ( noPollCtx ctx,
noPollOnMessageHandler  on_msg,
noPollPtr  user_data 

Allows to set a general handler to get notifications about a message received over any connection that is running under the provided context (noPollCtx).

ctxThe context where the notification will happen
on_msgThe handler to be called when an incoming message is received.
user_dataUser defined pointer that is passed in into the handler when called.

Note that the handler configured here will be overriden by the handler configured by nopoll_conn_set_on_msg

References nopoll_return_if_fail.