Searched refs:port (Results 1 - 21 of 21) sorted by relevance

/system/core/adb/
H A Dconsole.c8 int fd, port; local
10 port = adb_get_emulator_console_port();
11 if (port < 0) {
12 if (port == -2)
18 fd = socket_loopback_client( port, SOCK_STREAM );
20 fprintf(stderr, "error: could not connect to TCP port %d\n", port);
H A Dtransport_local.c108 int local_connect(int port) { argument
109 return local_connect_arbitrary_ports(port-1, port);
142 int port = DEFAULT_ADB_LOCAL_TRANSPORT_PORT; local
150 for ( ; count > 0; count--, port += 2 ) {
151 (void) local_connect(port);
162 int port = (int)arg; local
168 serverfd = socket_inaddr_any_server(port, SOCK_STREAM);
178 D("server: trying to get new connection from %d\n", port);
184 register_socket_transport(fd, "host", port,
244 const int port = (int)arg; local
302 local_init(int port) argument
[all...]
H A Dservices.c89 int port = (int)cookie; local
91 if (port <= 0) {
92 snprintf(buf, sizeof(buf), "invalid port\n");
98 snprintf(value, sizeof(value), "%d", port);
99 property_set("service.adb.tcp.port", value);
100 snprintf(buf, sizeof(buf), "restarting in TCP mode port: %d\n", port);
109 property_set("service.adb.tcp.port", "0");
333 int port = atoi(name + 4); local
336 ret = socket_loopback_client(port, SOCK_STREA
392 int port; local
437 int port, fd; local
[all...]
H A Dadb.h210 /* A listener is an entity which binds to a local port
211 ** and, upon receiving a connection on that port, creates
285 int init_socket_transport(atransport *t, int s, int port, int local);
292 int register_socket_transport(int s, const char *serial, int port, int local);
438 void local_init(int port);
439 int local_connect(int port);
H A Dadb_client.c41 int port; local
81 port = strtol(serial, NULL, 10);
82 return port;
229 fprintf(stdout,"* daemon not running. starting it now on port %d *\n",
H A Dsysdeps_win32.c579 int socket_loopback_client(int port, int type) argument
593 addr.sin_port = htons(port);
605 D("socket_loopback_client: could not connect to %s:%d\n", type != SOCK_STREAM ? "udp" : "tcp", port );
609 snprintf( f->name, sizeof(f->name), "%d(lo-client:%s%d)", _fh_to_int(f), type != SOCK_STREAM ? "udp:" : "", port );
610 D( "socket_loopback_client: port %d type %s => fd %d\n", port, type != SOCK_STREAM ? "udp" : "tcp", _fh_to_int(f) );
616 int socket_loopback_server(int port, int type) argument
632 addr.sin_port = htons(port);
656 snprintf( f->name, sizeof(f->name), "%d(lo-server:%s%d)", _fh_to_int(f), type != SOCK_STREAM ? "udp:" : "", port );
657 D( "socket_loopback_server: port
662 socket_network_client(const char *host, int port, int type) argument
704 socket_inaddr_any_server(int port, int type) argument
[all...]
H A Dsysdeps.h170 extern int socket_loopback_client(int port, int type);
171 extern int socket_network_client(const char *host, int port, int type);
172 extern int socket_loopback_server(int port, int type);
173 extern int socket_inaddr_any_server(int port, int type);
H A Dadb.c709 int port; local
713 port = atoi(name + 4);
716 ret = socket_inaddr_any_server(port, SOCK_STREAM);
718 ret = socket_loopback_server(port, SOCK_STREAM);
1181 /* Constructs a local name of form tcp:port.
1184 * server_port is the port number to use for the local name.
1254 int port; local
1302 /* don't listen on a port (default 5037) if running in secure mode */
1334 D("Local port disabled\n");
1350 // If one of these properties is set, also listen on that port
1511 int port = atoi(service+9); local
[all...]
H A Dtransport.c1000 int register_socket_transport(int s, const char *serial, int port, int local) argument
1010 D("transport: %s init'ing for socket %d, on port %d\n", serial, s, port);
1011 if (init_socket_transport(t, s, port, local) < 0) {
/system/core/toolbox/
H A Dsmd.c9 int fd, len, r, port = 0; local
15 port = atoi(argv[0] + 1);
20 sprintf(devname,"/dev/smd%d",port);
H A Dnetstat.c74 /* addr + : + port + \0 */
77 static void addr2str(int af, const void *addr, unsigned port, char *buf) argument
84 if (port) {
85 snprintf(buf+len, ADDR_LEN-len, ":%d", port);
/system/core/include/cutils/
H A Dsockets.h87 extern int socket_loopback_client(int port, int type);
88 extern int socket_network_client(const char *host, int port, int type);
89 extern int socket_loopback_server(int port, int type);
95 extern int socket_inaddr_any_server(int port, int type);
/system/core/libcutils/
H A Dsocket_inaddr_any_server.c35 /* open listen() port on any interface */
36 int socket_inaddr_any_server(int port, int type) argument
44 addr.sin_port = htons(port);
H A Dsocket_loopback_client.c33 /* Connect to port on the loopback IP interface. type is
37 int socket_loopback_client(int port, int type) argument
45 addr.sin_port = htons(port);
H A Dsocket_loopback_server.c35 /* open listen() port on loopback interface */
36 int socket_loopback_server(int port, int type) argument
44 addr.sin_port = htons(port);
H A Dsocket_network_client.c35 /* Connect to port on the IP interface. type is
39 int socket_network_client(const char *host, int port, int type) argument
51 addr.sin_port = htons(port);
/system/netd/
H A DFirewallController.cpp104 int FirewallController::setEgressDestRule(const char* addr, int protocol, int port, argument
115 sprintf(portStr, "%d", port);
H A DMDnsSdListener.h37 DNSServiceErrorType errorCode, const char *fullname, const char *hosttarget, uint16_t port,
119 const char *host, int port, int textLen, void *txtRecord);
H A DMDnsSdListener.cpp156 const char *domain, const char *host, int port, int txtLen, void *txtRecord) {
159 interfaceName, serviceName, serviceType, domain, host, port, txtLen);
163 port = htons(port);
173 serviceType, domain, host, port, txtLen, txtRecord, &MDnsSdListenerRegisterCallback,
244 DNSServiceErrorType errorCode, const char *fullname, const char *hosttarget, uint16_t port,
249 port = ntohs(port);
257 asprintf(&msg, "%d %s %s %d %d", refNumber, quotedFullName, quotedHostTarget, port, txtLen);
263 refNumber, fullname, hosttarget, port, txtLe
154 serviceRegister(SocketClient *cli, int requestId, const char *interfaceName, const char *serviceName, const char *serviceType, const char *domain, const char *host, int port, int txtLen, void *txtRecord) argument
243 MDnsSdListenerResolveCallback(DNSServiceRef sdRef, DNSServiceFlags flags, uint32_t interface, DNSServiceErrorType errorCode, const char *fullname, const char *hosttarget, uint16_t port, uint16_t txtLen, const unsigned char *txtRecord, void *inContext) argument
426 int port = atoi(argv[5]); local
[all...]
H A DCommandListener.cpp1513 int port = atoi(argv[3]); local
1517 res |= sFirewallCtrl->setEgressDestRule(addr, PROTOCOL_TCP, port, rule);
1518 res |= sFirewallCtrl->setEgressDestRule(addr, PROTOCOL_UDP, port, rule);
/system/media/camera/docs/
H A Dmetadata-check-dependencies25 if ! which port >& /dev/null
27 echo "Missing port binary, please install from http://www.macports.org/" >& 2
38 echo "sudo port install $1"

Completed in 198 milliseconds