summaryrefslogtreecommitdiff
path: root/src/ua.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/ua.c')
-rw-r--r--src/ua.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/ua.c b/src/ua.c
index 45102e4..7aeabd5 100644
--- a/src/ua.c
+++ b/src/ua.c
@@ -1798,6 +1798,8 @@ int uag_event_register(ua_event_h *h, void *arg)
if (!h)
return EINVAL;
+ uag_event_unregister(h);
+
eh = mem_zalloc(sizeof(*eh), eh_destructor);
if (!eh)
return ENOMEM;