From 921abd4623f256ee79927e4c4fe41b6188ee4c73 Mon Sep 17 00:00:00 2001 From: XMRig Date: Sun, 24 Nov 2019 00:53:58 +0700 Subject: [PATCH] #1309 Fixed null pointer dereference. --- src/backend/common/Workers.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/backend/common/Workers.cpp b/src/backend/common/Workers.cpp index 8e195b66a..ec47f9652 100644 --- a/src/backend/common/Workers.cpp +++ b/src/backend/common/Workers.cpp @@ -163,7 +163,7 @@ void xmrig::Workers::onReady(void *arg) assert(worker != nullptr); if (!worker || !worker->selfTest()) { - LOG_ERR("%s " RED("thread ") RED_BOLD("#%zu") RED(" self-test failed"), T::tag(), worker->id()); + LOG_ERR("%s " RED("thread ") RED_BOLD("#%zu") RED(" self-test failed"), T::tag(), worker ? worker->id() : 0); handle->backend()->start(worker, false); delete worker;