tldap_msg_received: Properly free the asn1_struct in case of an error
[metze/samba/wip.git] / source3 / lib / tldap.c
index aba8a25fbff0682c367c1b47a6c7ad326a645fc3..cbd9648007026e3e6fc15cfedd0817e07cbea0e2 100644 (file)
@@ -585,6 +585,7 @@ static void tldap_msg_received(struct tevent_req *subreq)
                /* Dump unexpected reply */
                tldap_debug(ld, TLDAP_DEBUG_WARNING, "tldap_msg_received: "
                            "No request pending for msg %d\n", id);
+               TALLOC_FREE(data);
                TALLOC_FREE(inbuf);
                goto done;
        }