From 80ea3c4f302b7a5b45c7699b6fee4472a94fd3fe Mon Sep 17 00:00:00 2001 From: lldxflwb <44514816+lldxflwb@users.noreply.github.com> Date: Fri, 2 Dec 2022 20:00:55 +0800 Subject: [PATCH] Fix a memory leak in the redis example (#1447) --- examples/redis/controllers/Client.cc | 2 ++ 1 file changed, 2 insertions(+) diff --git a/examples/redis/controllers/Client.cc b/examples/redis/controllers/Client.cc index 18bd89b3..19ed0f24 100644 --- a/examples/redis/controllers/Client.cc +++ b/examples/redis/controllers/Client.cc @@ -33,6 +33,8 @@ void Client::get(const HttpRequestPtr &, &json, &errors); + delete reader; + response["response"] = redisResponse; if (parsingSuccessful) {