From c46676daa5b23a7829ba2acbca2f950965d4ec06 Mon Sep 17 00:00:00 2001 From: Jfreegman Date: Tue, 1 Apr 2014 16:32:53 -0400 Subject: [PATCH] buffer needs to be empty --- src/prompt.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/prompt.c b/src/prompt.c index f5d4706..943cbf7 100644 --- a/src/prompt.c +++ b/src/prompt.c @@ -369,7 +369,7 @@ static void prompt_onConnectionChange(ToxWindow *self, Tox *m, int32_t friendnum ChatContext *ctx = self->chatwin; - uint8_t nick[TOX_MAX_NAME_LENGTH]; + uint8_t nick[TOX_MAX_NAME_LENGTH] = {0}; int n_len = tox_get_name(m, friendnum, nick); n_len = MIN(n_len, TOXIC_MAX_NAME_LENGTH-1);