From 484fcc959e98b18de08e9965bb27829db5b965cb Mon Sep 17 00:00:00 2001 From: dwarning Date: Thu, 8 Jun 2023 15:10:13 +0200 Subject: [PATCH] cleanup few warnings --- src/maths/sparse/spextra.c | 13 ++----------- 1 file changed, 2 insertions(+), 11 deletions(-) diff --git a/src/maths/sparse/spextra.c b/src/maths/sparse/spextra.c index 116b00053..de32918b4 100644 --- a/src/maths/sparse/spextra.c +++ b/src/maths/sparse/spextra.c @@ -40,22 +40,13 @@ int size = Matrix->Size; ASSERT_IS_SPARSE( Matrix ); -#if spCOMPLEX for (I = 1; I <= size; I++) { for (pElement = Matrix->FirstInCol[I]; pElement; pElement = pElement->NextInCol) { pElement->Real *= constant; +#if spCOMPLEX pElement->Imag *= constant; +#endif } } return; -#endif - - for (I = 1; I <= size; I++) { - pElement = Matrix->FirstInRow[I]; - while (pElement != NULL) - { pElement->Real *= constant; - pElement = pElement->NextInRow; - } - } - return; }