From c7564c699650d91d8565400572980be4176a8da2 Mon Sep 17 00:00:00 2001 From: cheetah Date: Thu, 17 Dec 2020 13:43:46 +0800 Subject: [PATCH] Fix memory corruption when destuct client object, callback clear thread not join. --- sources/core/client.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/sources/core/client.cpp b/sources/core/client.cpp index 659c0498..6c123d72 100644 --- a/sources/core/client.cpp +++ b/sources/core/client.cpp @@ -302,7 +302,8 @@ namespace cpp_redis { m_sync_condvar.notify_all(); }); - t.detach(); + // t.detach(); + t.join(); } void