X-Git-Url: http://sigrok.org/gitweb/?a=blobdiff_plain;f=src%2Foutput%2Fsrzip.c;h=787a2bab6f4a0be4c56051d8caa74e8fa97357e0;hb=da3d141f04e9a17bd41c5adfb5c83369fe3759df;hp=c101d3b263e42235a1e12be91b18977cedf7807a;hpb=2dbe445d55f0d7166bb481f4991e10bec4cd2789;p=libsigrok.git diff --git a/src/output/srzip.c b/src/output/srzip.c index c101d3b2..787a2bab 100644 --- a/src/output/srzip.c +++ b/src/output/srzip.c @@ -296,18 +296,6 @@ static int receive(const struct sr_output *o, const struct sr_datafeed_packet *p return SR_OK; } -static int cleanup(struct sr_output *o) -{ - struct out_context *outc; - - outc = o->priv; - g_free(outc->filename); - g_free(outc); - o->priv = NULL; - - return SR_OK; -} - static struct sr_option options[] = { ALL_ZERO }; @@ -320,6 +308,19 @@ static const struct sr_option *get_options(void) return options; } +static int cleanup(struct sr_output *o) +{ + struct out_context *outc; + + outc = o->priv; + g_variant_unref(options[0].def); + g_free(outc->filename); + g_free(outc); + o->priv = NULL; + + return SR_OK; +} + SR_PRIV struct sr_output_module output_srzip = { .id = "srzip", .name = "srzip",