Home
last modified time | relevance | path

Searched refs:servaddr (Results 1 – 7 of 7) sorted by relevance

/external/curl/docs/examples/
Dexternalsocket.c95 struct sockaddr_in servaddr; /* socket address structure */ in main() local
122 memset(&servaddr, 0, sizeof(servaddr)); in main()
123 servaddr.sin_family = AF_INET; in main()
124 servaddr.sin_port = htons(PORTNUM); in main()
126 servaddr.sin_addr.s_addr = inet_addr(IPADDR); in main()
127 if(INADDR_NONE == servaddr.sin_addr.s_addr) { in main()
132 if(connect(sockfd, (struct sockaddr *) &servaddr, sizeof(servaddr)) == in main()
/external/nanopb-c/examples/network_server/
Dclient.c110 struct sockaddr_in servaddr; in main() local
119 memset(&servaddr, 0, sizeof(servaddr)); in main()
120 servaddr.sin_family = AF_INET; in main()
121 servaddr.sin_addr.s_addr = htonl(INADDR_LOOPBACK); in main()
122 servaddr.sin_port = htons(1234); in main()
124 if (connect(sockfd, (struct sockaddr *)&servaddr, sizeof(servaddr)) != 0) in main()
Dserver.c118 struct sockaddr_in servaddr; in main() local
125 memset(&servaddr, 0, sizeof(servaddr)); in main()
126 servaddr.sin_family = AF_INET; in main()
127 servaddr.sin_addr.s_addr = htonl(INADDR_LOOPBACK); in main()
128 servaddr.sin_port = htons(1234); in main()
129 if (bind(listenfd, (struct sockaddr*)&servaddr, sizeof(servaddr)) != 0) in main()
/external/grpc-grpc/third_party/nanopb/examples/network_server/
Dclient.c114 struct sockaddr_in servaddr; in main() local
123 memset(&servaddr, 0, sizeof(servaddr)); in main()
124 servaddr.sin_family = AF_INET; in main()
125 servaddr.sin_addr.s_addr = htonl(INADDR_LOOPBACK); in main()
126 servaddr.sin_port = htons(1234); in main()
128 if (connect(sockfd, (struct sockaddr *)&servaddr, sizeof(servaddr)) != 0) in main()
Dserver.c114 struct sockaddr_in servaddr; in main() local
121 memset(&servaddr, 0, sizeof(servaddr)); in main()
122 servaddr.sin_family = AF_INET; in main()
123 servaddr.sin_addr.s_addr = htonl(INADDR_LOOPBACK); in main()
124 servaddr.sin_port = htons(1234); in main()
125 if (bind(listenfd, (struct sockaddr*)&servaddr, sizeof(servaddr)) != 0) in main()
/external/ltp/testcases/kernel/syscalls/bind/
Dbind02.c77 struct sockaddr_in servaddr; in try_bind() local
92 memset(&servaddr, 0, sizeof(servaddr)); in try_bind()
93 servaddr.sin_family = AF_INET; in try_bind()
94 servaddr.sin_port = htons(TCP_PRIVLEGED_COM_PORT); in try_bind()
95 servaddr.sin_addr.s_addr = htonl(INADDR_ANY); in try_bind()
96 r_value = bind(sockfd, (struct sockaddr *)&servaddr, sizeof(servaddr)); in try_bind()
/external/clang/tools/libclang/
DCIndexCodeCompletion.cpp774 struct sockaddr_in servaddr; in clang_codeCompleteAt_Impl() local
775 bzero(&servaddr, sizeof(servaddr)); in clang_codeCompleteAt_Impl()
776 servaddr.sin_family = AF_INET; in clang_codeCompleteAt_Impl()
777 servaddr.sin_port = htons(UDP_CODE_COMPLETION_LOGGER_PORT); in clang_codeCompleteAt_Impl()
779 &servaddr.sin_addr) <= 0) in clang_codeCompleteAt_Impl()
787 (struct sockaddr *)&servaddr, sizeof(servaddr)); in clang_codeCompleteAt_Impl()