From 29089c567bc5309526bb387e6b662d59a937b29c Mon Sep 17 00:00:00 2001 From: LoRd_MuldeR Date: Wed, 1 Jan 2014 17:50:56 +0100 Subject: [PATCH] Fixed number of tools (only relevant for DEBUG builds) + fixed an out-of-bounds array access in the error message. --- src/Thread_Initialization.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Thread_Initialization.cpp b/src/Thread_Initialization.cpp index ae3ea4f8..08dd4bbf 100644 --- a/src/Thread_Initialization.cpp +++ b/src/Thread_Initialization.cpp @@ -45,7 +45,7 @@ /* constants */ static const double g_allowedExtractDelay = 12.0; static const size_t BUFF_SIZE = 512; -static const size_t EXPECTED_TOOL_COUNT = 27; +static const size_t EXPECTED_TOOL_COUNT = 28; /* benchmark */ #undef ENABLE_BENCHMARK @@ -925,7 +925,7 @@ void InitializationThread::selfTest(void) } if(n != EXPECTED_TOOL_COUNT) { - qFatal("Tool count mismatch for CPU type %u !!!", cpu[4]); + qFatal("Tool count mismatch for CPU type %u !!!", cpu[k]); } qDebug("Done.\n"); }