g10: Fix memory leak.
authorJustus Winter <justus@g10code.com>
Thu, 30 Jun 2016 13:26:06 +0000 (15:26 +0200)
committerJustus Winter <justus@g10code.com>
Thu, 30 Jun 2016 16:50:16 +0000 (18:50 +0200)
* g10/compress.c (release_context): Free buffers.

Signed-off-by: Justus Winter <justus@g10code.com>
g10/compress.c

index bdddef1..c34beec 100644 (file)
@@ -295,6 +295,10 @@ compress_filter( void *opaque, int control,
 static void
 release_context (compress_filter_context_t *ctx)
 {
+  xfree(ctx->inbuf);
+  ctx->inbuf = NULL;
+  xfree(ctx->outbuf);
+  ctx->outbuf = NULL;
   xfree (ctx);
 }