From dde5fd8d38e31d1ce13c6d30b28838a8d8763480 Mon Sep 17 00:00:00 2001 From: Norbert Pocs Date: Tue, 12 Jul 2022 10:28:16 +0200 Subject: [PATCH] bind.c: Add missing size constant to err_msg Signed-off-by: Norbert Pocs Reviewed-by: Andreas Schneider (cherry picked from commit e53a2711d3e4459c06b4d8facaca7195902f0405) --- src/bind.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/bind.c b/src/bind.c index 7efac473..77acbb66 100644 --- a/src/bind.c +++ b/src/bind.c @@ -282,7 +282,7 @@ int ssh_bind_listen(ssh_bind sshbind) { } if (listen(fd, 10) < 0) { - char err_msg[] = {0}; + char err_msg[SSH_ERRNO_MSG_MAX] = {0}; ssh_set_error(sshbind, SSH_FATAL, "Listening to socket %d: %s", fd, ssh_strerror(errno, err_msg, SSH_ERRNO_MSG_MAX));