From a18cdfded1221b29560af4181a71378e64a9202d Mon Sep 17 00:00:00 2001 From: stammjo100588 Date: Mon, 10 Nov 2025 13:22:47 +0100 Subject: [PATCH] clear Matrix Fix for Test 3 --- matrix.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/matrix.c b/matrix.c index 490a0fc..d64a6e1 100644 --- a/matrix.c +++ b/matrix.c @@ -30,6 +30,8 @@ void clearMatrix(Matrix *matrix) { free(matrix->buffer); //gibt den heap speicher frei matrix->buffer = NULL; //zeiger auf NULL setzen + matrix->rows = 0; + matrix->cols = 0; } void setMatrixAt(MatrixType value, Matrix matrix, unsigned int rowIdx, unsigned int colIdx)