WAR: Set optnone for FwmarkClient::send to work around LLVM update bug.
Bug: 23239997
Without this attribute, we constantly see SocketClient unable to write
because of a broken pipe. Skipping optimizations on this function allows
things to work properly again.
Change-Id: I6b5a16a0bae86f4a12f59842b5563e0b815fcd9d
diff --git a/client/FwmarkClient.cpp b/client/FwmarkClient.cpp
index 5074a78..8e3be0c 100644
--- a/client/FwmarkClient.cpp
+++ b/client/FwmarkClient.cpp
@@ -44,7 +44,7 @@
}
}
-int FwmarkClient::send(FwmarkCommand* data, int fd) {
+int __attribute__((optnone)) FwmarkClient::send(FwmarkCommand* data, int fd) {
mChannel = socket(AF_UNIX, SOCK_STREAM | SOCK_CLOEXEC, 0);
if (mChannel == -1) {
return -errno;