From dbe1ba2749932f0c4acb461033ac39c24e5bdbae Mon Sep 17 00:00:00 2001 From: ENGO150 Date: Sun, 4 Dec 2022 18:59:27 +0100 Subject: [PATCH] fixed possible deallocation problem uninitialised --- src/core/lib/encrypter.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/core/lib/encrypter.c b/src/core/lib/encrypter.c index ffd75dc..de1ef78 100644 --- a/src/core/lib/encrypter.c +++ b/src/core/lib/encrypter.c @@ -51,7 +51,7 @@ outputFlags encryptText(char *text, char *keyNew) //VARIABLES char *key = malloc(getKeyLength() + 1); char *returningText; - char *textBuffer; + char *textBuffer = malloc(1); int *textKeyChain = malloc(sizeof(int) * strlen(text)); int numberBuffer; FILE *fileBuffer;