From ccdb4fce0e92057298729661d398f54ca6693a1f Mon Sep 17 00:00:00 2001 From: Evgeny Date: Fri, 22 Dec 2017 12:39:55 -0600 Subject: [PATCH] check for uninitialized context array on final dump in the case if the test failed --- test/ctrl/tool.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/ctrl/tool.cpp b/test/ctrl/tool.cpp index 8790c11af6..9da71e2e41 100644 --- a/test/ctrl/tool.cpp +++ b/test/ctrl/tool.cpp @@ -242,7 +242,7 @@ void dump_context_array() { exit(1); } - for (auto& v : *context_array) dump_context(&v.second); + if (context_array) for (auto& v : *context_array) dump_context(&v.second); if (pthread_mutex_unlock(&mutex) != 0) { perror("pthread_mutex_unlock");