From 5869f518cbd8b41b4c9880fc593216b9efeea430 Mon Sep 17 00:00:00 2001 From: Justus Winter Date: Thu, 30 Jun 2016 15:26:06 +0200 Subject: [PATCH] g10: Fix memory leak. * g10/compress.c (release_context): Free buffers. Signed-off-by: Justus Winter --- g10/compress.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/g10/compress.c b/g10/compress.c index bdddef134..c34beecf7 100644 --- a/g10/compress.c +++ b/g10/compress.c @@ -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); }