diff options
author | Mark Salyzyn <salyzyn@google.com> | 2014-04-29 00:41:32 +0000 |
---|---|---|
committer | Gerrit Code Review <noreply-gerritcodereview@google.com> | 2014-04-29 00:41:32 +0000 |
commit | 4095853133745ddaa1e37b46f9e7d4e8a2cdee28 (patch) | |
tree | a9777346b5a82e54c698f895271a99e6364c1df6 /logd/LogListener.cpp | |
parent | ab3d49b03527d5fc65664f66ddb78c98450c8c84 (diff) | |
parent | 8daa9af02dc0e63ce220e3fa95bf5fe4d6b7a99a (diff) | |
download | system_core-4095853133745ddaa1e37b46f9e7d4e8a2cdee28.zip system_core-4095853133745ddaa1e37b46f9e7d4e8a2cdee28.tar.gz system_core-4095853133745ddaa1e37b46f9e7d4e8a2cdee28.tar.bz2 |
Merge "logd: add thread setname"
Diffstat (limited to 'logd/LogListener.cpp')
-rw-r--r-- | logd/LogListener.cpp | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/logd/LogListener.cpp b/logd/LogListener.cpp index 1d0a51c..bc7622b 100644 --- a/logd/LogListener.cpp +++ b/logd/LogListener.cpp @@ -14,6 +14,7 @@ * limitations under the License. */ +#include <sys/prctl.h> #include <sys/socket.h> #include <sys/types.h> #include <sys/un.h> @@ -31,6 +32,8 @@ LogListener::LogListener(LogBuffer *buf, LogReader *reader) { } bool LogListener::onDataAvailable(SocketClient *cli) { + prctl(PR_SET_NAME, "logd.writer"); + char buffer[sizeof_log_id_t + sizeof(uint16_t) + sizeof(log_time) + LOGGER_ENTRY_MAX_PAYLOAD]; struct iovec iov = { buffer, sizeof(buffer) }; |