From d9bb246b3ea1cf259a0000656ed881b2ff464faa Mon Sep 17 00:00:00 2001 From: Victor Wagner Date: Wed, 27 Apr 2016 15:27:07 +0300 Subject: [PATCH] Fix resource leak --- src/substmap.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/substmap.c b/src/substmap.c index ac9b934..66346a8 100644 --- a/src/substmap.c +++ b/src/substmap.c @@ -51,7 +51,8 @@ SUBSTMAP read_substmap(char* filename) { } f=fopen(path,"rb"); if (!f) { - perror("catdoc"); + perror(path); + free(map); return NULL; } if (input_buffer) -- 2.39.5