From 4690640760983dffa9b28e257aac293da4282e85 Mon Sep 17 00:00:00 2001 From: Mark Salyzyn Date: Tue, 12 Jan 2016 10:08:03 -0800 Subject: [PATCH] logd: unaligned access on security buffer Bug: 26485626 Change-Id: I990447ca59982bb2de15decda575fd0e2838b5ed --- logd/LogListener.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/logd/LogListener.cpp b/logd/LogListener.cpp index 5348a2db6..846dd7c41 100644 --- a/logd/LogListener.cpp +++ b/logd/LogListener.cpp @@ -15,6 +15,7 @@ */ #include +#include #include #include #include @@ -46,7 +47,7 @@ bool LogListener::onDataAvailable(SocketClient *cli) { + LOGGER_ENTRY_MAX_PAYLOAD]; struct iovec iov = { buffer, sizeof(buffer) }; - char control[CMSG_SPACE(sizeof(struct ucred))]; + char control[CMSG_SPACE(sizeof(struct ucred))] __aligned(4); struct msghdr hdr = { NULL, 0,