From 0544aca649b11ab68e5fda513beb2d74caafd8ba Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C3=89milie=20Feral?= Date: Thu, 27 Sep 2018 15:33:21 +0200 Subject: [PATCH] [solver] Fix Solver with variable-length symbols --- apps/solver/equation_store.h | 2 +- apps/solver/solutions_controller.cpp | 1 - 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/apps/solver/equation_store.h b/apps/solver/equation_store.h index f39c6311e..497e391c3 100644 --- a/apps/solver/equation_store.h +++ b/apps/solver/equation_store.h @@ -20,7 +20,7 @@ public: TooManyVariables = -2, NonLinearSystem = -3, RequireApproximateSolution = -4, - VariableNameTooLong + VariableNameTooLong = -5 }; /* EquationStore */ EquationStore(); diff --git a/apps/solver/solutions_controller.cpp b/apps/solver/solutions_controller.cpp index a0a05212b..ba3a08622 100644 --- a/apps/solver/solutions_controller.cpp +++ b/apps/solver/solutions_controller.cpp @@ -160,7 +160,6 @@ void SolutionsController::willDisplayCellAtLocation(HighlightCell * cell, int i, break; default: int length = strlcpy(bufferSymbol, m_equationStore->variableAtIndex(j), Equation::k_maxVariableSize); - bufferSymbol[0] = m_equationStore->variableAtIndex(0); bufferSymbol[length++] = j+'0'; bufferSymbol[2] = 0; break;