diff --git a/src/bevent.c b/src/bevent.c index 8bea33e02..30c16b265 100644 --- a/src/bevent.c +++ b/src/bevent.c @@ -91,9 +91,9 @@ static enum bevent_class bevent_class(enum ua_event ev) case UA_EVENT_CREATE: case UA_EVENT_MWI_NOTIFY: case UA_EVENT_CUSTOM: + case UA_EVENT_SHUTDOWN: return BEVENT_CLASS_UA; - case UA_EVENT_SHUTDOWN: case UA_EVENT_EXIT: return BEVENT_CLASS_APP; diff --git a/src/ua.c b/src/ua.c index 9fbe1fe7c..86055b42e 100644 --- a/src/ua.c +++ b/src/ua.c @@ -426,7 +426,7 @@ unsigned ua_destroy(struct ua *ua) list_unlink(&ua->le); /* send the shutdown event */ - bevent_app_emit(UA_EVENT_SHUTDOWN, NULL, NULL); + bevent_ua_emit(UA_EVENT_SHUTDOWN, ua, NULL); /* terminate all calls now */ list_flush(&ua->calls);