Let SocketClient users write binary data to clients.
This is a dependency for the DNS proxy CLs.
This CL also adds a new socket for the netd process to inherit which
is owned by the inet group. (so only apps with the INTERNET
permission can use the DNS proxy...)
Change-Id: Ic3475c697913ba85805b4e49801b65e7a1d59289
diff --git a/include/sysutils/SocketClient.h b/include/sysutils/SocketClient.h
index e7fb177..2fcc331 100644
--- a/include/sysutils/SocketClient.h
+++ b/include/sysutils/SocketClient.h
@@ -28,8 +28,12 @@
uid_t getUid() const { return mUid; }
gid_t getGid() const { return mGid; }
+ // Send null-terminated C strings:
int sendMsg(int code, const char *msg, bool addErrno);
int sendMsg(const char *msg);
+
+ // Sending binary data:
+ int sendData(const void *data, int len);
};
typedef android::List<SocketClient *> SocketClientCollection;