From 1da02a79cb8628fe84e1b06f744d7b6390c89093 Mon Sep 17 00:00:00 2001 From: Luiz Augusto von Dentz Date: Thu, 19 Jul 2012 14:53:56 +0300 Subject: [PATCH] AVCTP: Fix not zeroing out buffer This could cause use of unitialized memory --- audio/avctp.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/audio/avctp.c b/audio/avctp.c index 9ef616174..074eabdd4 100644 --- a/audio/avctp.c +++ b/audio/avctp.c @@ -941,6 +941,8 @@ static int avctp_send(struct avctp *session, uint8_t transaction, uint8_t cr, sk = g_io_channel_unix_get_fd(session->io); + memset(buf, 0, sizeof(buf)); + avctp = (void *) buf; avc = (void *) &buf[AVCTP_HEADER_LENGTH]; -- 2.47.3