Searched defs:sock (Results 1 - 4 of 4) sorted by relevance

/frameworks/base/cmds/keystore/
H A Dkeystore_cli.cpp51 int sock = socket_local_client("keystore", ANDROID_SOCKET_NAMESPACE_RESERVED, local
53 if (sock == -1) {
58 send(sock, argv[1], 1, 0);
64 send(sock, &bytes, 2, 0);
65 send(sock, argv[i], length, 0);
67 shutdown(sock, SHUT_WR);
70 if (recv(sock, &code, 1, 0) != 1) {
76 while ((i = recv(sock, &bytes[0], 1, 0)) == 1) {
79 if ((i = recv(sock, &bytes[1], 1, 0)) != 1) {
85 i = recv(sock,
[all...]
H A Dkeystore_get.h44 int sock; local
49 sock = socket_local_client("keystore", ANDROID_SOCKET_NAMESPACE_RESERVED,
51 if (sock == -1) {
54 if (send(sock, &code, 1, 0) == 1 && send(sock, bytes, 2, 0) == 2 &&
55 send(sock, key, length, 0) == length && shutdown(sock, SHUT_WR) == 0 &&
56 recv(sock, &code, 1, 0) == 1 && code == /* NO_ERROR */ 1 &&
57 recv(sock, &bytes[0], 1, 0) == 1 && recv(sock,
[all...]
H A Dkeystore.cpp512 static int recv_code(int sock, int8_t* code) { argument
513 return recv(sock, code, 1, 0) == 1;
516 static int recv_message(int sock, uint8_t* message, int length) { argument
518 if (recv(sock, &bytes[0], 1, 0) != 1 ||
519 recv(sock, &bytes[1], 1, 0) != 1) {
529 int n = recv(sock, &message[offset], length - offset, 0);
539 static int recv_end_of_file(int sock) { argument
541 return recv(sock, &byte, 1, 0) == 0;
544 static void send_code(int sock, int8_t code) { argument
545 send(sock,
548 send_message(int sock, uint8_t* message, int length) argument
564 test(KeyStore* keyStore, int sock, uid_t uid, Value*, Value*) argument
568 get(KeyStore* keyStore, int sock, uid_t uid, Value* keyName, Value*) argument
581 insert(KeyStore* keyStore, int sock, uid_t uid, Value* keyName, Value* val) argument
588 del(KeyStore* keyStore, int sock, uid_t uid, Value* keyName, Value*) argument
594 exist(KeyStore* keyStore, int sock, uid_t uid, Value* keyName, Value*) argument
603 saw(KeyStore* keyStore, int sock, uid_t uid, Value* keyPrefix, Value*) argument
624 reset(KeyStore* keyStore, int sock, uid_t uid, Value*, Value*) argument
634 password(KeyStore* keyStore, int sock, uid_t uid, Value* pw, Value*) argument
652 lock(KeyStore* keyStore, int sock, uid_t uid, Value*, Value*) argument
657 unlock(KeyStore* keyStore, int sock, uid_t uid, Value* pw, Value* unused) argument
661 zero(KeyStore* keyStore, int sock, uid_t uid, Value*, Value*) argument
718 process(KeyStore* keyStore, int sock, uid_t uid, int8_t code) argument
777 int sock; local
[all...]
/frameworks/base/opengl/libs/GLES2_dbg/test/
H A Dtest_socket.cpp36 int sock; member in class:SocketContextTest
40 SocketContextTest() : sock(-1) {
55 sock = socks[1];
63 close(sock);
79 ASSERT_EQ(sizeof(len), send(sock, &len, sizeof(len), 0));
80 ASSERT_EQ(str.length(), send(sock, str.data(), str.length(), 0));
85 ASSERT_EQ(0, ioctl(sock, FIONREAD, &available));
88 ASSERT_EQ(sizeof(len), recv(sock, &len, sizeof(len), 0));
94 ASSERT_EQ(len, recv(sock, buffer, len, 0));
105 ASSERT_EQ(0, ioctl(sock, FIONREA
[all...]

Completed in 649 milliseconds