s4/messaging: let the imessaging ctx destructor free msg_dgm_ref
[sfrench/samba-autobuild/.git] / source4 / lib / messaging / messaging.c
index ea50627c2bd286c7397c9c2383c2c53adb9ba87d..d0beef662410f679e143a4e835dd0fa4996bd70c 100644 (file)
@@ -304,6 +304,7 @@ static struct imessaging_context *msg_ctxs;
 static int imessaging_context_destructor(struct imessaging_context *msg)
 {
        DLIST_REMOVE(msg_ctxs, msg);
+       TALLOC_FREE(msg->msg_dgm_ref);
        return 0;
 }