From: Bert Vermeulen Date: Wed, 28 May 2014 13:46:43 +0000 (+0200) Subject: session: Free session-wide trigger if set. X-Git-Tag: libsigrok-0.4.0~1298 X-Git-Url: https://sigrok.org/gitaction?a=commitdiff_plain;h=3d68b6126d4fd670c317db497ade19314f7f8b56;p=libsigrok.git session: Free session-wide trigger if set. --- diff --git a/session.c b/session.c index 742619a6..86d641ef 100644 --- a/session.c +++ b/session.c @@ -106,10 +106,9 @@ SR_API int sr_session_destroy(void) } sr_session_dev_remove_all(); - - /* TODO: Error checks needed? */ - g_mutex_clear(&session->stop_mutex); + if (session->trigger) + sr_trigger_free(session->trigger); g_free(session); session = NULL;