From: Victor Wagner Date: Wed, 27 Apr 2016 12:27:07 +0000 (+0300) Subject: Fix resource leak X-Git-Tag: REL_0_95~1^2~1 X-Git-Url: http://wagner.pp.ru/gitweb/?a=commitdiff_plain;h=d9bb246b3ea1cf259a0000656ed881b2ff464faa;p=oss%2Fcatdoc.git Fix resource leak --- 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)