From 733f81269ccbc45c8d5e5f5807a94e685ce0c0d4 Mon Sep 17 00:00:00 2001 From: Phenom Date: Fri, 21 Jul 2017 15:20:04 +0200 Subject: [PATCH] Fix CppCheck Error in utility_functions.c /supportlibs/pegmarkdown/utility_functions.c:28: error: Cppcheck(memleak): Memory leak: new --- supportlibs/pegmarkdown/utility_functions.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/supportlibs/pegmarkdown/utility_functions.c b/supportlibs/pegmarkdown/utility_functions.c index 50fc35035..08f910274 100644 --- a/supportlibs/pegmarkdown/utility_functions.c +++ b/supportlibs/pegmarkdown/utility_functions.c @@ -25,6 +25,8 @@ element * cons(element *new, element *list) { element *reverse(element *list) { element *new = NULL; element *next = NULL; +#warning Phenom (2017-07-21): I don't know if it is a real memLeak for new. If not remove this warning and add a comment how it is deleted. + // cppcheck-suppress memleak while (list != NULL) { next = list->next; new = cons(list, new);