libubus.h: add ubus_auto_shutdown()
authorBen Kelly <[email protected]>
Tue, 2 Feb 2016 13:02:59 +0000 (15:02 +0200)
committerFelix Fietkau <[email protected]>
Sun, 7 Feb 2016 13:24:28 +0000 (14:24 +0100)
commit6a86e65f7d4836bfe387d213a6dfaea1d5d162dd
tree40d427cc80ad11a47b646aac51dd61dcbe1814df
parent619f3a160de4f417226b69039538882787b3811c
libubus.h: add ubus_auto_shutdown()

Add ubus_auto_shutdown function, which ensures any pending uloop_timer is cancelled before calling ubus_shutdown on the context.

This avoids a condition where ubus_shutdown() is called during ubus_auto_connect attempting a reconnection.

Signed-off-by: Ben Kelly <[email protected]>
libubus.h