Home
last modified time | relevance | path

Searched refs:setsockopt (Results 1 – 25 of 54) sorted by relevance

123

/system/netd/libnetdutils/
DSocketOption.cpp32 return sys.setsockopt(sock, level, optname, &on, sizeof(on)); in enableSockopt()
40 RETURN_IF_NOT_OK(sys.setsockopt(sock, SOL_TCP, TCP_KEEPIDLE, &idleTime, sizeof(idleTime))); in enableTcpKeepAlives()
43 RETURN_IF_NOT_OK(sys.setsockopt(sock, SOL_TCP, TCP_KEEPCNT, &numProbes, sizeof(numProbes))); in enableTcpKeepAlives()
46 RETURN_IF_NOT_OK(sys.setsockopt(sock, SOL_TCP, TCP_KEEPINTVL, &probeInterval, in enableTcpKeepAlives()
DSyscallsTest.cpp91 TEST_F(SyscallsTest, setsockopt) { in TEST_F() argument
99 EXPECT_CALL(mSyscalls, setsockopt(kFd, kLevel, kOptname, &expected, sizeof(expected))) in TEST_F()
101 EXPECT_EQ(status::ok, sys.setsockopt(kFd, kLevel, kOptname, expected)); in TEST_F()
105 EXPECT_CALL(mSyscalls, setsockopt(kFd, kLevel, kOptname, &expected, sizeof(expected))) in TEST_F()
107 EXPECT_EQ(kError, sys.setsockopt(kFd, kLevel, kOptname, expected)); in TEST_F()
DSyscalls.cpp77 Status setsockopt(Fd sock, int level, int optname, const void* optval, in setsockopt() function in android::netdutils::RealSyscalls
79 auto rv = ::setsockopt(sock.get(), level, optname, optval, optlen); in setsockopt()
/system/vold/
DNetlinkManager.cpp65 if ((setsockopt(mSock, SOL_SOCKET, SO_RCVBUFFORCE, &sz, sizeof(sz)) < 0) && in start()
66 (setsockopt(mSock, SOL_SOCKET, SO_RCVBUF, &sz, sizeof(sz)) < 0)) { in start()
71 if (setsockopt(mSock, SOL_SOCKET, SO_PASSCRED, &on, sizeof(on)) < 0) { in start()
/system/core/libcutils/
Duevent.cpp110 if (setsockopt(s, SOL_SOCKET, SO_RCVBUF, &buf_sz, sizeof(buf_sz)) < 0 || in uevent_open_socket()
120 if (setsockopt(s, SOL_SOCKET, SO_RCVBUFFORCE, &buf_sz, sizeof(buf_sz)) < 0) { in uevent_open_socket()
126 setsockopt(s, SOL_SOCKET, SO_PASSCRED, &on, sizeof(on)); in uevent_open_socket()
Dsocket_inaddr_any_server_windows.cpp53 if (setsockopt(sock, SOL_SOCKET, SO_EXCLUSIVEADDRUSE, (char*)&exclusive, in socket_inaddr_any_server()
55 setsockopt(sock, IPPROTO_IPV6, IPV6_V6ONLY, (char*)&v6_only, in socket_inaddr_any_server()
Dsocket_inaddr_any_server_unix.cpp47 setsockopt(s, SOL_SOCKET, SO_REUSEADDR, (const char *) &n, sizeof(n)); in socket_inaddr_any_server()
Dsockets_windows.cpp58 return setsockopt(sock, SOL_SOCKET, SO_RCVTIMEO, in socket_set_receive_timeout()
Dsocket_local_server_unix.cpp80 setsockopt(s, SOL_SOCKET, SO_REUSEADDR, &n, sizeof(n));
Dsockets_unix.cpp38 return setsockopt(sock, SOL_SOCKET, SO_RCVTIMEO, &tv, sizeof(tv)); in socket_set_receive_timeout()
/system/netd/server/
DNetlinkManager.cpp87 if (setsockopt(*sock, SOL_SOCKET, SO_RCVBUFFORCE, &sz, sizeof(sz)) < 0 && in setupSocket()
88 setsockopt(*sock, SOL_SOCKET, SO_RCVBUF, &sz, sizeof(sz)) < 0) { in setupSocket()
94 if (setsockopt(*sock, SOL_SOCKET, SO_PASSCRED, &on, sizeof(on)) < 0) { in setupSocket()
/system/extras/tests/tcp_nuke_addr/
Dtcp_nuke_addr_test.cpp36 if (setsockopt(s, SOL_SOCKET, SO_LINGER, &l, sizeof(l)) == -1) { in setSoLinger()
40 if (setsockopt(s, SOL_TCP, TCP_LINGER2, &nolinger, sizeof(nolinger)) == -1) { in setSoLinger()
/system/core/adb/
Dsysdeps.h181 #undef setsockopt
182 #define setsockopt ___xxx_setsockopt macro
547 return setsockopt( fd, level, optname, optval, optlen ); in adb_setsockopt()
550 #undef setsockopt
551 #define setsockopt ___xxx_setsockopt macro
Dtest_adb.py42 serversock.setsockopt(socket.SOL_SOCKET, socket.SO_REUSEADDR, 1)
295 sock.setsockopt(socket.SOL_SOCKET, socket.SO_LINGER,
311 listener.setsockopt(socket.SOL_SOCKET, socket.SO_REUSEADDR, 1)
/system/bt/osi/src/socket_utils/
Dsocket_local_server.cc66 setsockopt(s, SOL_SOCKET, SO_REUSEADDR, &n, sizeof(n));
/system/netd/libnetdutils/include/netdutils/
DSyscalls.h55 virtual Status setsockopt(Fd sock, int level, int optname, const void* optval,
130 Status setsockopt(Fd sock, int level, int optname, const SockoptT& opt) const { in setsockopt() function
131 return setsockopt(sock, level, optname, &opt, sizeof(opt)); in setsockopt()
DMockSyscalls.h42 MOCK_CONST_METHOD5(setsockopt, Status(Fd sock, int level, int optname, const void* optval,
/system/core/debuggerd/client/
Ddebuggerd_client.cpp100 if (setsockopt(sockfd, SOL_SOCKET, SO_RCVTIMEO, &timeout, sizeof(timeout)) != 0) { in debuggerd_trigger_dump()
104 if (setsockopt(sockfd, SOL_SOCKET, SO_SNDTIMEO, &timeout, sizeof(timeout)) != 0) { in debuggerd_trigger_dump()
/system/extras/multinetwork/
Dhttpurl.cpp150 setsockopt(fd, SOL_SOCKET, SO_RCVTIMEO, &timeo, sizeof(timeo)); in makeTcpSocket()
151 setsockopt(fd, SOL_SOCKET, SO_SNDTIMEO, &timeo, sizeof(timeo)); in makeTcpSocket()
/system/core/libappfuse/
DFuseBuffer.cc152 if (setsockopt(fds[0], SOL_SOCKET, SO_SNDBUF, &kMaxMessageSize, sizeof(int)) != 0 || in SetupMessageSockets()
153 setsockopt(fds[1], SOL_SOCKET, SO_SNDBUF, &kMaxMessageSize, sizeof(int)) != 0) { in SetupMessageSockets()
/system/bt/hci/src/
Dbtsnoop_net.cc104 if (setsockopt(listen_socket_, SOL_SOCKET, SO_REUSEADDR, &enable, in listen_fn_()
/system/core/logd/
DLogListener.cpp157 if (setsockopt(sock, SOL_SOCKET, SO_PASSCRED, &on, sizeof(on))) { in getLogSocket()
/system/bt/vendor_libs/test_vendor_lib/test/
Dasync_manager_unittest.cc51 EXPECT_FALSE(setsockopt(fd, SOL_SOCKET, SO_REUSEADDR, &reuse_flag, sizeof(reuse_flag)) < 0); in StartServer()
/system/core/adb/sysdeps/posix/
Dnetwork.cpp101 setsockopt(s.get(), SOL_SOCKET, SO_REUSEADDR, &n, sizeof(n)); in _network_loopback_server()
/system/netd/tests/
Dtun_interface.cpp138 if (setsockopt(s, SOL_SOCKET, SO_RCVTIMEO, &timeout, sizeof(timeout)) == -1) return -errno; in addAddress()

123