summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMark Salyzyn2014-03-18 17:30:17 -0500
committerMark Salyzyn2014-03-18 18:03:34 -0500
commitb059cf53c9185702e99345b7319bcb075ffc5bee (patch)
tree04206d261fbc28177368b5f34ec7de904b96ecb3 /logd/LogListener.cpp
parent6c92369cbea460fded7e85f9751c6938000f504a (diff)
downloadplatform-system-core-b059cf53c9185702e99345b7319bcb075ffc5bee.tar.gz
platform-system-core-b059cf53c9185702e99345b7319bcb075ffc5bee.tar.xz
platform-system-core-b059cf53c9185702e99345b7319bcb075ffc5bee.zip
logd: Logging is truncated
- stack buffer undersized Bug: 13514601 Change-Id: I3e5dda2daa7531ddcacece33dfdecaa28dcca765
Diffstat (limited to 'logd/LogListener.cpp')
-rw-r--r--logd/LogListener.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/logd/LogListener.cpp b/logd/LogListener.cpp
index c6b248bdc..2aa2ebb00 100644
--- a/logd/LogListener.cpp
+++ b/logd/LogListener.cpp
@@ -31,7 +31,8 @@ LogListener::LogListener(LogBuffer *buf, LogReader *reader)
31{ } 31{ }
32 32
33bool LogListener::onDataAvailable(SocketClient *cli) { 33bool LogListener::onDataAvailable(SocketClient *cli) {
34 char buffer[1024]; 34 char buffer[sizeof_log_id_t + sizeof(log_time) + sizeof(char)
35 + LOGGER_ENTRY_MAX_PAYLOAD];
35 struct iovec iov = { buffer, sizeof(buffer) }; 36 struct iovec iov = { buffer, sizeof(buffer) };
36 memset(buffer, 0, sizeof(buffer)); 37 memset(buffer, 0, sizeof(buffer));
37 38