From fe013e0a813c5697e917da642143388de60e8528 Mon Sep 17 00:00:00 2001 From: Jason Dillaman Date: Fri, 24 Apr 2015 00:21:15 -0400 Subject: [PATCH] librbd: TaskFinisher should finish all queued tasks The destructor wasn't waiting for all Finisher tasks to complete before stopping the thread. Signed-off-by: Jason Dillaman (cherry picked from commit 8e20240e4155e2f0398e79f4c0095d2d6ba1d4cb) --- src/librbd/TaskFinisher.h | 1 + 1 file changed, 1 insertion(+) diff --git a/src/librbd/TaskFinisher.h b/src/librbd/TaskFinisher.h index 14dcd3011fd0c..4942a38bbdc21 100644 --- a/src/librbd/TaskFinisher.h +++ b/src/librbd/TaskFinisher.h @@ -35,6 +35,7 @@ public: delete m_safe_timer; } + m_finisher->wait_for_empty(); m_finisher->stop(); delete m_finisher; } -- 2.39.5