100+ results results for 'socket repo:jgasteiz/security-camera' (809 ms)
141 * @param buf ByteBuffer - the buffer containing the data, we will write as long as <code>(buf.hasRemaining()==true)</code> 142 * @param socket SocketChannel - the socket to write data to 143 * @param selector Selector - the selector to use for blocking, if null then a busy write will be initiated 201 * @param buf ByteBuffer - the buffer containing the data, we will read as until we have read at least one byte or we timed out 202 * @param socket SocketChannel - the socket to write data to 203 * @param selector Selector - the selector to use for blocking, if null then a busy read will be initiated 206 * @throws EOFException if read returns -1 207 * @throws SocketTimeoutException if the read times out 208 * @throws IOException if an IO Exception occurs in the underlying socket logic 209 */ 210 public int read(ByteBuffer buf, NioChannel socket, Selector selector, long readTimeout) throws IOException { 211 return read(buf,socket,selector,readTimeout,true); 218 * @param buf ByteBuffer - the buffer containing the data, we will read as until we have read at least one byte or we timed out 219 * @param socket SocketChannel - the socket to write data to 220 * @param selector Selector - the selector to use for blocking, if null then a busy read will be initiatedRecordingInputStream.java https://gitlab.com/essere.lab.public/qualitas.class-corpus | Java | 369 lines
30import java.io.InputStream; 31import java.net.SocketException; 32import java.net.SocketTimeoutException; 211 } 212 } catch (SocketTimeoutException e) { 213 // A socket timeout is just a transient problem, meaning 220 if (logger.isLoggable(Level.FINE)) { 221 logger.log(Level.FINE, "socket timeout", e); 222 } 224 recordingOutputStream.checkLimits(); 225 } catch (SocketException se) { 226 throw se;auth.go https://gitlab.com/masterlike/masterlike-bot | Go | 467 lines
97 for socket.cachedNonce == "" && socket.dead == nil { 98 debugf("Socket %p to %s: waiting for nonce", socket, socket.addr) 99 socket.gotNonce.Wait() 131 } 132 debugf("Socket %p to %s: nonce unmarshalled: %#v", socket, socket.addr, result) 133 if result.Code == 13390 { 180 181 debugf("Socket %p to %s: login: db=%q user=%q", socket, socket.addr, cred.Source, cred.Username) 182 198 } else { 199 debugf("Socket %p to %s: login successful", socket, socket.addr) 200 } 461 copy(socket.logout[i:], socket.logout[i+1:]) 462 socket.logout = socket.logout[:len(socket.logout)-1] 463 return truegitaly_client_spec.rb https://gitlab.com/wolfgang42/gitlab-ce | Ruby | 419 lines
127 128 context 'when passed a UNIX socket address' do 129 it 'passes the address as-is to GRPC' doremote_fetcher.rb https://gitlab.com/pooja043/Globus_Docker_3 | Ruby | 507 lines
62 63 Socket.do_not_reverse_lookup = true 64 244 raise FetchError.new('timed out', uri.to_s) 245 rescue IOError, SocketError, SystemCallError => e 246 raise FetchError.new("#{e.class}: #{e}", uri.to_s)netop.c https://gitlab.com/envieidoc/advancedtomato2 | C | 528 lines
21#include <sys/types.h> 22#include <sys/socket.h> 23#include <arpa/inet.h> 62 do { 63 lsock = socket( AF_INET, SOCK_STREAM, 0 ); 64 if( -1 == lsock ) break; 82 83 rc = setsockopt( lsock, SOL_SOCKET, SO_REUSEADDR, 84 &ON, sizeof(ON) ); 95 TRACE( (void)tmfprintf (g_flog, "Setting low watermark for " 96 "server socket [%d] to [%d]\n", lsock, wmark) ); 97 rc = setsockopt (lsock, SOL_SOCKET, SO_RCVLOWAT, 115 if(errno) 116 mperror(g_flog, errno, "%s: socket/bind/listen error", 117 __func__);pptp_callmgr.c https://gitlab.com/envieidoc/tomato | C | 388 lines
10#include <sys/stat.h> 11#include <sys/socket.h> 12#include <netinet/in.h> 121 fatal("Invalid IP address: %s", argv[1]); 122 /* Step 1: Open sockets. */ 123 if ((inet_sock = open_inetsock(inetaddr)) < 0) 125 if ((unix_sock = open_unixsock(inetaddr)) < 0) 126 fatal("Could not open unix socket for %s", argv[1]); 127 /* Step 1b: FORK and return status to calling process. */ 137 file2fd("/dev/null", "wb", STDERR_FILENO); 138 /* Step 1c: Clean up unix socket on TERM */ 139 if (sigsetjmp(callmgr_env, 1) != 0) 187 break; 188 /* Step 5b: Handle new connection to UNIX socket */ 189 if (FD_ISSET(unix_sock, &read_set)) {int_homun.c https://gitlab.com/gumiko/hercules | C | 367 lines
31#include "common/showmsg.h" 32#include "common/socket.h" 33#include "common/sql.h"adm_err.c https://github.com/richlowe/illumos-gate.git | C | 520 lines
443 return(dgettext(TEXT_DOMAIN, 444 "Could not create socket")); 445 case 144: 449 return(dgettext(TEXT_DOMAIN, 450 "Could not fetch local socket address")); 451 case 146:3.8.3.md https://github.com/rabbitmq/rabbitmq-server.git | Markdown | 305 lines
41 42 * Reduced scheduled GC activity in connection socket writer to one run per 1 GiB of data transferred, with an option to change the value or disable scheduled run entirely. 43 More frequent binary heap GC runs seem unneccesary on Erlang 22.mach-gta02.c https://github.com/devpress-xx/linux-2.6.git | C | 582 lines
147 * On GTA02 the 1A charger features a 48K resistor to 0V on the ID pin. 148 * We use this to recognize that we can pull 1A from the USB socket. 149 *README.md https://gitlab.com/nguyenthehiep3232/marius | Markdown | 495 lines
3[](https://www.npmjs.com/package/ws) 4[](https://github.com/websockets/ws/actions?query=workflow%3ACI+branch%3Amaster) 5[](https://coveralls.io/github/websockets/ws) 15communication. Browser clients must use the native 16[`WebSocket`](https://developer.mozilla.org/en-US/docs/Web/API/WebSocket) 17object. To make the same code work seamlessly on Node.js and the browser, you 288 289A client WebSocket broadcasting to all connected WebSocket clients, including 290itself. 461 462const client = new WebSocket('wss://echo.websocket.org/'); 463 494[ws-server-options]: 495 https://github.com/websockets/ws/blob/master/doc/ws.md#new-websocketserveroptions-callback 496winrt_ssocket_service_base.hpp https://gitlab.com/cdeclare/intcrypt | C++ Header | 357 lines
1// 2// detail/winrt_ssocket_service_base.hpp 3// ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 10 11#ifndef BOOST_ASIO_DETAIL_WINRT_SSOCKET_SERVICE_BASE_HPP 12#define BOOST_ASIO_DETAIL_WINRT_SSOCKET_SERVICE_BASE_HPP 24#include <boost/asio/io_service.hpp> 25#include <boost/asio/socket_base.hpp> 26#include <boost/asio/detail/addressof.hpp> 27#include <boost/asio/detail/buffer_sequence_adapter.hpp> 28#include <boost/asio/detail/socket_types.hpp> 29#include <boost/asio/detail/winrt_async_manager.hpp> 42 // The native type of a socket. 43 typedef Windows::Networking::Sockets::StreamSocket^ native_handle_type; 44test_in_http.rb https://gitlab.com/vectorci/fluentd | Ruby | 442 lines
8 def startup 9 socket_manager_path = ServerEngine::SocketManager::Server.generate_path 10 @server = ServerEngine::SocketManager::Server.open(socket_manager_path) 10 @server = ServerEngine::SocketManager::Server.open(socket_manager_path) 11 ENV['SERVERENGINE_SOCKETMANAGER_PATH'] = socket_manager_path.to_s 12 endHttpConnectionPoolBuilder.java https://gitlab.com/vincent.hsu/cyberduck | Java | 253 lines
42import org.apache.http.config.SocketConfig; 43import org.apache.http.conn.socket.ConnectionSocketFactory; 44import org.apache.http.conn.socket.PlainConnectionSocketFactory; 126 final ProxyFinder proxy, 127 final SocketFactory socketFactory) { 128 this(host, new PlainConnectionSocketFactory() { 129 @Override 130 public Socket createSocket(final HttpContext context) throws IOException { 131 return socketFactory.createSocket(); 157 public HttpConnectionPoolBuilder(final Host host, 158 final ConnectionSocketFactory socketFactory, 159 final ConnectionSocketFactory sslSocketFactory, 186 final int timeout = preferences.getInteger("connection.timeout.seconds") * 1000; 187 builder.setDefaultSocketConfig(SocketConfig.custom() 188 .setTcpNoDelay(true)https.d.ts https://gitlab.com/girmayegebremedhin/student_managment | TypeScript Typings | 156 lines
49 addListener(event: 'resumeSession', listener: (sessionId: Buffer, callback: (err: Error, sessionData: Buffer) => void) => void): this; 50 addListener(event: 'secureConnection', listener: (tlsSocket: tls.TLSSocket) => void): this; 51 addListener(event: 'tlsClientError', listener: (err: Error, tlsSocket: tls.TLSSocket) => void): this; 96 once(event: string, listener: (...args: any[]) => void): this; 97 once(event: 'keylog', listener: (line: Buffer, tlsSocket: tls.TLSSocket) => void): this; 98 once(event: 'newSession', listener: (sessionId: Buffer, sessionData: Buffer, callback: (err: Error, resp: Buffer) => void) => void): this; 118 prependListener(event: 'secureConnection', listener: (tlsSocket: tls.TLSSocket) => void): this; 119 prependListener(event: 'tlsClientError', listener: (err: Error, tlsSocket: tls.TLSSocket) => void): this; 120 prependListener(event: 'close', listener: () => void): this; 130 prependOnceListener(event: string, listener: (...args: any[]) => void): this; 131 prependOnceListener(event: 'keylog', listener: (line: Buffer, tlsSocket: tls.TLSSocket) => void): this; 132 prependOnceListener(event: 'newSession', listener: (sessionId: Buffer, sessionData: Buffer, callback: (err: Error, resp: Buffer) => void) => void): this; 135 prependOnceListener(event: 'secureConnection', listener: (tlsSocket: tls.TLSSocket) => void): this; 136 prependOnceListener(event: 'tlsClientError', listener: (err: Error, tlsSocket: tls.TLSSocket) => void): this; 137 prependOnceListener(event: 'close', listener: () => void): this;TrustSpecifiedOkHttpClient.java https://gitlab.com/samuel-davis/DDF-TestSource | Java | 301 lines
49 X509TrustManager trustManager; 50 SSLSocketFactory sslSocketFactory; 51 60 ); 61 sslSocketFactory = sslContext.getSocketFactory(); 62 } catch (GeneralSecurityException e) { 68 builder.readTimeout(readTimeout, TimeUnit.SECONDS); 69 builder.sslSocketFactory(sslSocketFactory, trustManager); 70 82 X509TrustManager trustManager; 83 SSLSocketFactory sslSocketFactory; 84 ArrayList<String> certArray = getCertDirectoryFileNames(); 94 ); 95 sslSocketFactory = sslContext.getSocketFactory(); 96 } catch (GeneralSecurityException e) {introduction.html https://bitbucket.org/preining/tex-live.git | HTML | 333 lines
21<tr><td align=center><a href="http://www.lua.org"> 22<img width=128 height=128 border=0 alt="LuaSocket" src="luasocket.png"> 23</a></td></tr> 61The API design had two goals in mind. First, users 62experienced with the C API to sockets should feel comfortable using LuaSocket. 63Second, the simplicity and the feel of the Lua language should be 130Master sockets are newly created TCP sockets returned by the function 131<a href=tcp.html#tcp><tt>socket.tcp</tt></a>. A master socket is 132transformed into a server socket 182-- load namespace 183local socket = require("socket") 184-- create a TCP socket and bind it to the local host, at any port 287-- load namespace 288local socket = require("socket") 289-- convert host name to ip addressmodule-util.html https://bitbucket.org/esatterwhite/wallace-io.git | HTML | 769 lines
271 <li> 272 <a href="module-XDM.Socket.html">Socket</a> 273 </li>select.c https://bitbucket.org/ddevine/haiku.git | C | 492 lines
85static BOOL 86IsSocketHandle(HANDLE h) 87{ 95 ev.lNetworkEvents = 0xDEADBEEF; 96 WSAEnumNetworkEvents ((SOCKET) h, NULL, &ev); 97 return ev.lNetworkEvents != 0xDEADBEEF; 324 325 /* Classify handles. Create fd sets for sockets, poll the others. */ 326 for (i = 0; i < nfds; i++) 337 338 if (IsSocketHandle (h)) 339 { 341 342 /* See above; socket handles are mapped onto select, but we 343 need to map descriptors to handles. */w.c https://bitbucket.org/killerpenguinassassins/open_distrib_devel.git | C | 528 lines
56#include <sys/ioctl.h> 57#include <sys/socket.h> 58#include <sys/tty.h>workhorse_spec.rb https://gitlab.com/Ben305/gitlab-ce | Ruby | 454 lines
99 100 describe '.terminal_websocket' do 101 def terminal(ca_pem: nil) 125 context 'without ca_pem' do 126 subject { described_class.terminal_websocket(terminal) } 127 131 context 'with ca_pem' do 132 subject { described_class.terminal_websocket(terminal(ca_pem: "foo")) } 133index.js https://gitlab.com/bethalice523/WebAPI | JavaScript | 328 lines
211 212 describe('unix domain sockets', function(){ 213 it('without auth', function(done){http.pm https://bitbucket.org/preining/tex-live.git | Perl | 501 lines
29 30 local($^W) = 0; # IO::Socket::INET can be noisy 31 my $sock = $self->socket_class->new(PeerAddr => $host, 161 # connect to remote site 162 my $socket = $self->_new_socket($host, $port, $timeout); 163 322 my $buf = $socket->_rbuf; 323 my $n = $socket->sysread($buf, 1024, length($buf)); 324 unless (defined $n) { 395 if ($method eq "CONNECT") { 396 $response->{client_socket} = $socket; # so it can be picked up 397 return $response; 436 { 437 $conn_cache->deposit($self->socket_type, "$host:$port", $socket); 438 }SOCK_Connector.cpp https://github.com/InkVisible/wow.git | C++ | 365 lines
6#include "ace/OS_NS_unistd.h" 7#include "ace/OS_NS_sys_socket.h" 8#include "ace/os_include/os_fcntl.h" 39 40 // Only open a new socket if we don't already have a valid handle. 41 if (new_stream.get_handle () == ACE_INVALID_HANDLE 61 62 // Only open a new socket if we don't already have a valid handle. 63 if (new_stream.get_handle () == ACE_INVALID_HANDLE 123#if defined(ACE_WIN32) 124 // In order to detect when the socket that has been 125 // bound to is in TIME_WAIT we need to do the connect 130 // error state. The error code is then retrieved with 131 // getsockopt(). Good sockets however will return from 132 // the select() with ETIME - in this case returnboard-dm365-evm.c https://github.com/kingklick/kk-incredible-kernel.git | C | 491 lines
100 101/* NOTE: this is geared for the standard config, with a socketed 102 * 2 GByte Micron NAND (MT29F16G08FAA) using 128KB sectors. If youarvcameratest.c https://gitlab.com/subin.plakkannickal/aravis | C | 420 lines
17static int arv_option_gain = -1; 18static gboolean arv_option_auto_socket_buffer = FALSE; 19static gboolean arv_option_no_packet_resend = FALSE; 26static gboolean arv_option_high_priority = FALSE; 27static gboolean arv_option_no_packet_socket = FALSE; 28static char *arv_option_chunks = NULL; 78 "auto", 'a', 0, G_OPTION_ARG_NONE, 79 &arv_option_auto_socket_buffer, "Auto socket buffer size", NULL 80 }, 118 "no-packet-socket", '\0', 0, G_OPTION_ARG_NONE, 119 &arv_option_no_packet_socket, "Disable use of packet socket", NULL 120 }, 341 g_object_set (stream, 342 "socket-buffer", ARV_GV_STREAM_SOCKET_BUFFER_AUTO, 343 "socket-buffer-size", 0,upnp.go https://gitlab.com/shinvdu/syncthing | Go | 440 lines
129 130 socket, err := net.ListenMulticastUDP("udp4", intf, &net.UDPAddr{IP: ssdp.IP}) 131 if err != nil { 134 } 135 defer socket.Close() // Make sure our socket gets closed 136 136 137 err = socket.SetDeadline(time.Now().Add(timeout)) 138 if err != nil { 144 145 _, err = socket.WriteTo(search, ssdp) 146 if err != nil { 155 resp := make([]byte, 65536) 156 n, _, err := socket.ReadFrom(resp) 157 if err != nil {process.c https://gitlab.com/grayhamster/io.js | C | 524 lines
114 115int uv__make_socketpair(int fds[2], int flags) { 116#if defined(__linux__) 121 122 if (socketpair(AF_UNIX, SOCK_STREAM | UV__SOCK_CLOEXEC | flags, 0, fds) == 0) 123 return 0; 135 136 if (socketpair(AF_UNIX, SOCK_STREAM, 0, fds)) 137 return -errno; 202 else 203 return uv__make_socketpair(fds, 0); 204main.cc https://bitbucket.org/kbw/wb-samples.git | C++ | 522 lines
54 int getHandle() const; 55 zmq::socket_t* getSocket() const; 56 133 134zmq::socket_t* Stream::getSocket() const 135{ 276 277 if (zmq::socket_t* zsock = pstream->getSocket()) { 278 zmq_pollitem_t rec = { static_cast<void*>(zsock), -1, zmq_mode, 0 }; 412 if (Bundle* reader_bundle = new Bundle("reader")) { 413 zmq::socket_t* pub = new zmq::socket_t(ctx, zmq::socket_type::pub); 414 pub->bind("inproc://news.znc"); 422 if (Bundle* writer_bundle = new Bundle("writer")) { 423 zmq::socket_t* sub = new zmq::socket_t(ctx, zmq::socket_type::sub); 424 sub->connect("inproc://news.znc");jboss-as-mod-cluster_1_2.xsd https://gitlab.com/mucadoo/geo-marvel | XML Schema | 277 lines
48 49 <!-- Get the actual advertiseGroupAddress / advertisePort from advertiseSocket --> 50 <xs:attribute name="advertise-socket" type="xs:string" use="optional"/> 75 </xs:attribute> 76 <xs:attribute name="socket-timeout" type="xs:int" use="optional" default="20"> 77 <xs:annotation> 185 <xs:documentation> 186 sslProtocol: Overrides the default SSL socket protocol. 187 </xs:documentation>connect.hpp https://github.com/BorisSchaeling/asio.git | C++ Header | 389 lines
51template <typename Protocol, typename SocketService, typename Iterator> 52inline Iterator connect(basic_socket<Protocol, SocketService>& s, 53 Iterator begin, asio::error_code& ec) 68template <typename Protocol, typename SocketService, typename Iterator> 69inline Iterator connect(basic_socket<Protocol, SocketService>& s, 70 Iterator begin, Iterator end, asio::error_code& ec) 177 public: 178 connect_op(basic_socket<Protocol, SocketService>& sock, 179 const Iterator& begin, const Iterator& end, 256 //private: 257 basic_socket<Protocol, SocketService>& socket_; 258 Iterator iter_; 354 typename ConnectCondition, typename ComposedConnectHandler> 355inline void async_connect(basic_socket<Protocol, SocketService>& s, 356 Iterator begin, ConnectCondition connect_condition,CDProtocol.java https://gitlab.com/Moylle/CDAPI | Java | 481 lines
14 public AfterVerificationDelegate afterVerification; 15 Socket socket; 16 InputStream inputStream; 42 43 public CDProtocol(Socket socket, int maxLength, int buf_capacity, boolean incomming) throws Exception 44 { 46 } 47 public CDProtocol(Socket socket, int maxLength, int buf_capacity, boolean incomming, String hashedKeyWord, DataInputObject dio, RawDataInputObject dioRaw, boolean useBigEndian) throws Exception 48 { 48 { 49 this.socket = socket; 50 this.inputStream = socket.getInputStream(); 272 { 273 return this.socket != null && this.socket.isConnected(); 274 }record-handler.js https://gitlab.com/jasonparser/deepstream.io | JavaScript | 369 lines
111 * 112 * @param {SocketWrapper} socketWrapper the socket that send the request 113 * @param {Object} message parsed and validated message 133 * 134 * @param {SocketWrapper} socketWrapper the socket that send the request 135 * @param {Object} message parsed and validated message 171 * @param {Object} record 172 * @param {SocketWrapper} socketWrapper the socket that send the request 173 * 204 * 205 * @param {SocketWrapper} socketWrapper the socket that send the request 206 * @param {Object} message parsed and validated message 346 * 347 * @param {SocketWrapper} socketWrapper the socket that send the request 348 * @param {Object} message parsed and validated messageopenvswitch.m4 https://github.com/homework/openvswitch.git | m4 | 356 lines
53 [HAVE_NETLINK=no], 54 [#include <sys/socket.h> 55 #include <linux/types.h> 98 99dnl Checks for libraries needed by lib/socket-util.c. 100AC_DEFUN([OVS_CHECK_SOCKET_LIBS], 100AC_DEFUN([OVS_CHECK_SOCKET_LIBS], 101 [AC_CHECK_LIB([socket], [connect]) 102 AC_SEARCH_LIBS([gethostbyname], [resolv], [RESOLVER_LIBS=-lresolv])])intel.c https://github.com/erasmux/cm-kernel.git | C | 531 lines
87 * 88 * It is also reliable across cores and sockets. (but not across 89 * cabinets - we turn it off in that case explicitly.)mpisocketserver.h https://gitlab.com/benbelga/muscleHPC | C Header | 405 lines
265 266class SocketManager: public SocketServer{ 267 305//********************************** TCPSocketManager ******************************************* 306class TCPSocketManager: public SocketManager{ 307 327 328class SocketKernel: public SocketServer{ 329 377 378class MpiSocketKernel: public SocketKernel{ 379 391 392class TCPSocketKernel: public SocketKernel{ 393WeiXinSvcImpl.java https://gitlab.com/spiderworts/ab_pc_cms | Java | 358 lines
27import org.apache.http.conn.scheme.SchemeRegistry; 28import org.apache.http.conn.ssl.SSLSocketFactory; 29import org.apache.http.entity.StringEntity; 312 ctx.init(null, new TrustManager[] { tm }, null); 313 SSLSocketFactory ssf = new SSLSocketFactory(ctx); 314 ssf.setHostnameVerifier(SSLSocketFactory.ALLOW_ALL_HOSTNAME_VERIFIER);client.js https://gitlab.com/oytunistrator/x3dom | JavaScript | 495 lines
53 54 "socketTimeout": function(test){ 55 var client = simplesmtp.connect(PORT_NUMBER, false, {socketTimeout: 500});Krb5AndCertsSslSocketConnector.Krb5SslFilter.html https://gitlab.com/essere.lab.public/qualitas.class-corpus | HTML | 144 lines
6<TITLE> 7Uses of Class org.apache.hadoop.security.Krb5AndCertsSslSocketConnector.Krb5SslFilter (Hadoop 1.1.2 API) 8</TITLE> 17 if (location.href.indexOf('is-external=true') == -1) { 18 parent.document.title="Uses of Class org.apache.hadoop.security.Krb5AndCertsSslSocketConnector.Krb5SslFilter (Hadoop 1.1.2 API)"; 19 } 41 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A> </TD> 42 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../org/apache/hadoop/security/Krb5AndCertsSslSocketConnector.Krb5SslFilter.html" title="class in org.apache.hadoop.security"><FONT CLASS="NavBarFont1"><B>Class</B></FONT></A> </TD> 43 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> <FONT CLASS="NavBarFont1Rev"><B>Use</B></FONT> </TD> 60<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2"> 61 <A HREF="../../../../../index.html?org/apache/hadoop/security//class-useKrb5AndCertsSslSocketConnector.Krb5SslFilter.html" target="_top"><B>FRAMES</B></A> 62 <A HREF="Krb5AndCertsSslSocketConnector.Krb5SslFilter.html" target="_top"><B>NO FRAMES</B></A> 83<H2> 84<B>Uses of Class<br>org.apache.hadoop.security.Krb5AndCertsSslSocketConnector.Krb5SslFilter</B></H2> 85</CENTER>ClientFTP.java https://gitlab.com/essere.lab.public/qualitas.class-corpus | Java | 179 lines
54 protected StringBuilder controlConversation; 55 protected Socket dataSocket; 56 71 * the path of the file to retrieve 72 * @return the socket to read data from, or null if server says not found, 73 * permission denied, etc 76 */ 77 public Socket openDataConnection(int command, String path) 78 throws IOException { 79 try { 80 dataSocket = _openDataConnection_(command, path); 81 if (dataSocket != null) { 82 recordAdditionalInfo("Opened data connection to " 83 + dataSocket.getInetAddress().getHostAddress() + ":" 84 + dataSocket.getPort());ColumbaServer.java https://gitlab.com/essere.lab.public/qualitas.class-corpus | Java | 251 lines
22import java.io.PrintWriter; 23import java.net.ServerSocket; 24import java.net.Socket; 40/** 41 * Opens a server socket to manage multiple sessions of Columba capable of 42 * passing commands to the main session. 81 */ 82 protected ServerSocket serverSocket; 83 102 try { 103 serverSocket.close(); 104 135 try { 136 serverSocket = new ServerSocket(port); 137RuntimeEnabledFeatures.cpp https://gitlab.com/x33n/phantomjs | C++ | 213 lines
36#include "SharedWorkerRepository.h" 37#include "WebSocket.h" 38 143 144#if ENABLE(WEB_SOCKETS) 145bool RuntimeEnabledFeatures::webSocketEnabled() 146{ 147 return WebSocket::isAvailable(); 148}unistd.h https://github.com/cnm/ts7500_kernel.git | C Header | 402 lines
84#define __NR_fstatfs 100 85#define __NR_socketcall 102 86#define __NR_syslog 103 372#define __ARCH_WANT_SYS_UTIME 373#define __ARCH_WANT_SYS_SOCKETCALL 374#define __ARCH_WANT_SYS_FADVISE64core-connection.h https://gitlab.com/brian0218/rk3066_r-box_android4.2.2_sdk | C Header | 169 lines
31 32// Socket timeout in millisec (set to 5 seconds) 33#define CORE_PORT_TIMEOUT_MS 5000 38 * Return: 39 * Sync socket descriptor on success, or -1 on failure, with errno appropriately 40 * set. 41 */ 42SyncSocket* core_connection_open_socket(SockAddress* sockaddr); 43 45 * Param: 46 * console_socket Socket address for the console. 47 * Return: 125/* Creates a console client, and switches it to a given stream. 126 * console_socket Socket address for the console. 127 * stream_name Name of the stream to switch to.swarmnode.yaml https://gitlab.com/unofficial-mirrors/openstack-magnum | YAML | 459 lines
296 297 write_docker_socket: 298 type: "OS::Heat::SoftwareConfig" 300 group: ungrouped 301 config: {get_file: ../../common/templates/swarm/fragments/write-docker-socket.yaml} 302 340 params: 341 "$NODE_SERVICES": "docker.socket docker swarm-agent" 342 381 - config: {get_resource: add_docker_daemon_options} 382 - config: {get_resource: write_docker_socket} 383 - config: {get_resource: add_proxy}README.md https://gitlab.com/rickyvaughn2/Pi-GPIO-Server | Markdown | 243 lines
1# angular-socket-io [](https://travis-ci.org/btford/angular-socket-io) 2 91. `bower install angular-socket-io` or [download the zip](https://github.com/btford/angular-socket-io/archive/master.zip). 102. Make sure the Socket.IO client lib is loaded. It's often served at `/socket.io/socket.io.js`. 113. Include the `socket.js` script provided by this component into your app. 80 81`socket.forward` allows you to forward the events received by Socket.IO's socket to AngularJS's event system. 82You can then listen to the event with `$scope.$on`. 129 130This option allows you to provide the `socket` service with a `Socket.IO socket` object to be used internally. 131This is useful if you want to connect on a different path, or need to hold a reference to the `Socket.IO socket` object for use elsewhere. 140 mySocket = socketFactory({ 141 ioSocket: myIoSocket 142 }); 223]). 224factory('socket', function (socketFactory) { 225 return socketFactory({IPAddress.cs https://github.com/ambroff/mono.git | C# | 511 lines
31using System.Globalization; 32using System.Net.Sockets; 33using System.Runtime.InteropServices; 42 // Don't change the name of this field without also 43 // changing socket-io.c in the runtime 44 // The IP address is stored in little-endian order inside the int, 368 if (m_Family != AddressFamily.InterNetworkV6) 369 throw new SocketException ((int) SocketError.OperationNotSupported); 370 374 if (m_Family != AddressFamily.InterNetworkV6) 375 throw new SocketException ((int) SocketError.OperationNotSupported); 376 if ((value < 0) || (value > UInt32.MaxValue))TcpTransport.java https://github.com/Cyberqat/Red-Dwarf.git | Java | 359 lines
26import com.sun.sgs.nio.channels.AsynchronousServerSocketChannel; 27import com.sun.sgs.nio.channels.AsynchronousSocketChannel; 28import com.sun.sgs.nio.channels.CompletionHandler; 35import java.net.InetAddress; 36import java.net.InetSocketAddress; 37import java.util.Properties; 76 * argument to the 77 * {@link AsynchronousServerSocketChannel#bind(SocketAddress,int) 78 * AsynchronousServerSocketChannel.bind} method. 103 /** The listen address. */ 104 final InetSocketAddress listenAddress; 105 119 /** The acceptor for listening for new connections. */ 120 volatile AsynchronousServerSocketChannel acceptor; 121il2simulator.cpp https://github.com/CorvusCorax/my_OpenPilot_mods.git | C++ | 363 lines
98{ 99 inSocket->connectToHost(host,inPort); // IL2 100 if(!inSocket->waitForConnected()) 121 QByteArray data = cmd.toAscii(); 122 //outSocket->write(data); 123 inSocket->write(data); // for IL2 must send to the same port as input!!!!!!!!!!!!!best-practice-security.md https://gitlab.com/HDworley/expressjs.com | Markdown | 205 lines
27 28您可能熟悉 Secure Socket Layer (SSL) 加密。[TLS 就是 SSL 後繼的演進](https://msdn.microsoft.com/en-us/library/windows/desktop/aa380515(v=vs.85).aspx)。換句話說,如果您之前使用 SSL,請考量升級至 TLS。一般而言,我們建議由 Nginx 來處理 TLS。如需有關在 Nginx(和其他伺服器)上配置 TLS 的適當參考資料,請參閱 [Recommended Server Configurations (Mozilla Wiki)](https://wiki.mozilla.org/Security/Server_Side_TLS#Recommended_Server_Configurations)。 29analyze.h https://bitbucket.org/encukou/patched-po.git | C Header | 187 lines
139 /* The connection to the outside */ 140 Network &socket(); 141 const Network &socket() const; 142 /* To tell if its the registry we're connected to*/ 143 bool registry_socket; 144 147 148 Network mysocket; 149};netlink.h https://bitbucket.org/apanda/ovs-ddc.git | C Header | 164 lines
30 * For Netlink protocol definitions, see netlink-protocol.h. For 31 * Linux-specific definitions for Netlink sockets, see netlink-socket.h. 32 */Makefile.in https://github.com/cciechad/brlcad.git | Autoconf | 466 lines
157LIBSGIGL = @LIBSGIGL@ 158LIBSOCKET = @LIBSOCKET@ 159LIBSTDCXX = @LIBSTDCXX@logger.cc https://gitlab.com/jonnialva90/iridium-browser | C++ | 366 lines
139 140void Logger::LogNewSocketEvent(const CastSocket& cast_socket) { 141 DCHECK(thread_checker_.CalledOnValidThread()); 148 aggregated_socket_event.set_endpoint_id(ip.back()); 149 aggregated_socket_event.set_channel_auth_type(cast_socket.channel_auth() == 150 CHANNEL_AUTH_TYPE_SSL 300 301 std::deque<proto::SocketEvent>& socket_events = it->second->socket_events; 302 if (socket_events.size() >= kMaxEventsPerSocket) { 326 log.add_aggregated_socket_event(); 327 new_aggregated_socket_event->CopyFrom(it->second->aggregated_socket_event); 328 328 329 const std::deque<SocketEvent>& socket_events = it->second->socket_events; 330 for (std::deque<SocketEvent>::const_iterator socket_event_it =TcpTransport.java https://github.com/Cyberqat/Red-Dwarf.git | Java | 390 lines
77 * argument to the 78 * {@link AsynchronousServerSocketChannel#bind(SocketAddress,int) 79 * AsynchronousServerSocketChannel.bind} method. 131 132 /** The client socket timeout */ 133 private final Integer socketTimeout; 138 /** The acceptor for listening for new connections. */ 139 volatile AsynchronousServerSocketChannel acceptor; 140 169 170 socketTimeout = wrappedProps.getIntProperty(SOCKET_TIMEOUT_PROPERTY, 171 0, 0, Integer.MAX_VALUE); 219 "\n " + LISTEN_PORT_PROPERTY + "=" + port + 220 "\n " + SOCKET_TIMEOUT_PROPERTY + "=" + socketTimeout); 22158-debug_spec.js https://gitlab.com/farm-assistant/nodered | JavaScript | 338 lines
19var helper = require("../../helper.js"); 20var WebSocket = require('ws'); 21 46 var n1 = helper.getNode("n1"); 47 websocket_test(function() { 48 n1.emit("input", {payload:"test"}); 62 var count = 0; 63 websocket_test(function() { 64 n1.emit("input", {payload:"test"}); 91 var n1 = helper.getNode("n1"); 92 websocket_test(function() { 93 n1.emit("input", {payload:"test"}); 106 var n1 = helper.getNode("n1"); 107 websocket_test(function() { 108 n1.emit("input", {payload:"test", foo:"bar"});NetworkElement.h https://github.com/midnightcoder/gracula.git | C Header | 344 lines
47 48 class ServerSocket; 49 106 pthread_t socketListenerThread; // thread which will listen to the port 107 pthread_attr_t socketListenerAttr; 108 static bool stopListenerThreadFlag; // control flag used to make listener thread finish and return. 108 static bool stopListenerThreadFlag; // control flag used to make listener thread finish and return. 109 static bool socketListenerIsReady; // control flag used to indicate listener is ready. 110 127 128 static std::vector<ServerSocket*> serverSockets; 129 269 // ***********************************************/ 270 // ServerSocket call-back 271util.h https://gitlab.com/cr3pt/nkernel | C Header | 268 lines
69#include <sys/poll.h> 70#include <sys/socket.h> 71#include <sys/ioctl.h>svr-x11fwd.c https://gitlab.com/envieidoc/tomato | C | 241 lines
64 65 /* create listening socket */ 66 fd = socket(PF_INET, SOCK_STREAM, 0); 84 85 /* listener code will handle the socket now. 86 * No cleanup handler needed, since listener_remove only happens 103 104/* accepts a new X11 socket */ 105/* returns DROPBEAR_FAILURE or DROPBEAR_SUCCESS */ 235 /* otherwise it was an error we don't know about */ 236 dropbear_log(LOG_DEBUG, "Failed to bind x11 socket"); 237 break;configure.in https://gitlab.com/envieidoc/tomato | Autoconf | 239 lines
55 CFLAGS="$CFLAGS -D_XOPEN_SOURCE=500 -D__EXTENSIONS__" 56 LDFLAGS="-lxnet -ldevinfo -lnsl -lsocket -lrt" 57fi 94AC_TRY_COMPILE([#include <sys/types.h> 95#include <sys/socket.h>], 96 [socklen_t x; x = 1; return x;], 115AC_TYPE_SIGNAL 116AC_CHECK_FUNCS(mktime select socket) 117AC_CHECK_FUNCS(clock_gettime) 210 #include <sys/types.h> 211 #include <sys/socket.h> 212 ], [errno.h https://gitlab.com/envieidoc/tomato | C Header | 139 lines
99#define EUSERS 87 /* Too many users */ 100#define ENOTSOCK 88 /* Socket operation on non-socket */ 101#define EDESTADDRREQ 89 /* Destination address required */ 102#define EMSGSIZE 90 /* Message too long */ 103#define EPROTOTYPE 91 /* Protocol wrong type for socket */ 104#define ENOPROTOOPT 92 /* Protocol not available */ 105#define EPROTONOSUPPORT 93 /* Protocol not supported */ 106#define ESOCKTNOSUPPORT 94 /* Socket type not supported */ 107#define EOPNOTSUPP 95 /* Operation not supported on transport endpoint */tcp_probe.c https://gitlab.com/envieidoc/sprd_project | C | 260 lines
24#include <linux/kprobes.h> 25#include <linux/socket.h> 26#include <linux/tcp.h>client.js https://gitlab.com/varunkothamachu/hack.chat | JavaScript | 282 lines
51function join(channel) { 52 ws = new WebSocket('ws://' + document.domain + ':6060') 53 // ws = new WebSocket('wss://' + document.domain + '/chat-ws')MemoryFileSystem.js https://gitlab.com/ricky1477/twitter-clone | JavaScript | 225 lines
57 isFIFO: falseFn, 58 isSocket: falseFn 59 }; 67 isFIFO: falseFn, 68 isSocket: falseFn 69 };ConstituentParserServer.java https://gitlab.com/neuralconcept/NLPthirdParty | Java | 195 lines
27import java.io.UnsupportedEncodingException; 28import java.net.ServerSocket; 29import java.net.Socket; 74 String kafToString; 75 ServerSocket socketServer = null; 76 Socket activeSocket; 82 System.out.println("-> Trying to listen port... " + port); 83 socketServer = new ServerSocket(port); 84 System.out.println("-> Connected and listening to port " + port); 86 try { 87 activeSocket = socketServer.accept(); 88 inFromClient = new BufferedReader(new InputStreamReader(activeSocket.getInputStream(), "UTF-8")); 88 inFromClient = new BufferedReader(new InputStreamReader(activeSocket.getInputStream(), "UTF-8")); 89 outToClient = new BufferedWriter(new OutputStreamWriter(activeSocket.getOutputStream(), "UTF-8")); 90 //get data from clientvhci_sysfs.c https://gitlab.com/webhaikal/SenseiOneplus3 | C | 252 lines
41 * output example: 42 * prt sta spd dev socket local_busid 43 * 000 004 000 000 c5a7bb80 1-2.3 45 * 46 * IP address can be retrieved from a socket pointer address by looking 47 * up /proc/net/{tcp,tcp6}. Also, a userland program may remember a 50 out += sprintf(out, 51 "prt sta spd bus dev socket local_busid\n"); 52 175 struct vhci_device *vdev; 176 struct socket *socket; 177 int sockfd = 0; 225 vdev->speed = speed; 226 vdev->ud.tcp_socket = socket; 227 vdev->ud.status = VDEV_ST_NOTASSIGNED;LocalDescriptions.properties https://github.com/rhusar/wildfly.git | Properties File | 203 lines
76web.connector.scheme=The web connector scheme. 77web.connector.socket-binding=The web connector socket-binding reference, this connector should be bound to. 78web.connector.enabled=Defines whether the connector should be started on startup. 80web.connector.enable-lookups=Enable DNS lookups for Servlet API. 81web.connector.proxy-binding=The socket binding to define the host and port that will be used when sending a redirect. The default value is null. 82web.connector.proxy-name=The host name that will be used when sending a redirect. The default value is null. 86web.connector.secure=Indicates if content sent or received by the connector is secured from the user perspective. 87web.connector.redirect-binding=The socket binding to define the port for redirection to a secure connector. 88web.connector.redirect-port=The port for redirection to a secure connector.CompositeX509KeyManager.scala https://gitlab.com/KiaraGrouwstra/playframework | Scala | 165 lines
10import java.security.cert.{ CertificateException, X509Certificate } 11import java.net.Socket 12import scala.collection.mutable.ArrayBuffer 47 48 def chooseClientAlias(keyType: Array[String], issuers: Array[Principal], socket: Socket): String = { 49 logger.debug(s"chooseClientAlias: keyType = ${keyType.toSeq}, issuers = ${issuers.toSeq}, socket = $socket") 51 withKeyManagers { keyManager => 52 val clientAlias = keyManager.chooseClientAlias(keyType, issuers, socket) 53 if (clientAlias != null) { 110 111 def chooseServerAlias(keyType: String, issuers: Array[Principal], socket: Socket): String = { 112 logger.debug(s"chooseServerAlias: keyType = $keyType, issuers = ${issuers.toSeq}, socket = $socket") 113 withKeyManagers { keyManager => 114 val serverAlias = keyManager.chooseServerAlias(keyType, issuers, socket) 115 if (serverAlias != null) {test.sh https://gitlab.com/kush/jarulraj-postgresql-cpp | Shell | 229 lines
40 LISTEN_ADDRESSES="" 41 # Select a socket directory. The algorithm is from the "configure" 42 # script; the outcome mimics pg_regress.c:make_temp_sockdir(). 54 { 55 echo "could not create socket temporary directory in \"/tmp\"" 56 exit 1connect_job.h https://github.com/chromium/chromium.git | C Header | 334 lines
189 // ConnectJob completes. 190 StreamSocket* socket() { return socket_.get(); } 191 253 protected: 254 const SocketTag& socket_tag() const { return socket_tag_; } 255 ClientSocketFactory* client_socket_factory() { 279 280 void SetSocket(std::unique_ptr<StreamSocket> socket, 281 absl::optional<std::set<std::string>> dns_aliases); 315 RequestPriority priority_; 316 const SocketTag socket_tag_; 317 raw_ptr<const CommonConnectJobParams> common_connect_job_params_; 320 raw_ptr<Delegate> delegate_; 321 std::unique_ptr<StreamSocket> socket_; 322 // Indicates if this is the topmost ConnectJob. The topmost ConnectJob logs anconfig.h https://github.com/thesjg/DragonFlyBSD.git | C Header | 392 lines
108 * 109 * For UNIX domain sockets (default on Linux and BSD): This is a 110 * directory that will be created for UNIX domain sockets for listening 111 * to requests from external programs (CLI/GUI, etc.) for status 112 * information and configuration. The socket file will be named based 113 * on the interface name, so multiple %wpa_supplicant processes can be 114 * run at the same time if more than one interface is used. 115 * /var/run/wpa_supplicant is the recommended directory for sockets and 116 * by default, wpa_cli will use it when trying to connect with 120 * by setting the directory to allow only members of a group 121 * to use sockets. This way, it is possible to run 122 * %wpa_supplicant as root (since it needs to change network 122 * %wpa_supplicant as root (since it needs to change network 123 * configuration and open raw sockets) and still allow GUI/CLI 124 * components to be run as non-root users. However, since the__init__.py https://github.com/SlapOS/slapos.git | Python | 330 lines
103 self.log_directory, # CP/var/log - log container 104 self.run_directory, # CP/var/run - working container - pids, sockets 105 self.tmp_directory, # CP/tmp - temporary files_stream_writable.js https://github.com/bigeasy/node.git | JavaScript | 453 lines
76 // of how much we're waiting to get pushed to some underlying 77 // socket or file. 78 this.length = 0;GossipServerSession.java https://github.com/joninvski/Appia.git | Java | 425 lines
167 try { 168 RegisterSocketEvent rse=new RegisterSocketEvent(ev.getChannel(),Direction.DOWN,this); 169 rse.go(); 243 244 private void handleRegisterSocketEvent(RegisterSocketEvent ev) { 245 if (!ev.getChannel().getChannelID().equals(GROUP_NAME+" Channel")) { 254 if (gossips == null) { 255 gossips=new InetSocketAddress[] { new InetSocketAddress(ev.localHost,my_port) }; 256 } else { 261 if (i >= gossips.length) { 262 InetSocketAddress[] aux=new InetSocketAddress[gossips.length+1]; 263 System.arraycopy(gossips,0,aux,0,gossips.length); 274 Endpt[] view=new Endpt[] { new Endpt() }; 275 InetSocketAddress[] addrs=new InetSocketAddress[] { new InetSocketAddress(ev.localHost, ev.port) }; 276 ViewState vs=new ViewState("1",new Group(GROUP_NAME),new ViewID(0,view[0]),new ViewID[0], view, addrs);net_connection.h https://github.com/nardo/tnl2.git | C Header | 395 lines
208 209 _last_send_sequence = _interface->get_socket_interface()->send_to_connection(_interface->get_socket(), _connection, stream.get_next_byte_position(), stream.get_buffer()); 210 //torque_connection_send_to(_connection, stream.get_next_byte_position(), stream.get_buffer(), &_last_send_sequence); 298 // make sure we don't try to overwrite the maximum packet size 299 if(_current_packet_send_size > net::udp_socket::max_datagram_size) 300 _current_packet_send_size = net::udp_socket::max_datagram_size; 310 { 311 return _notify_queue_head && (_last_send_sequence - _notify_queue_head->sequence >= torque_sockets_packet_window_size - 2); 312 }UnixDomainSocket.java https://github.com/carrot-garden/carrot-jnlper.git | Java | 458 lines
46 { 47 UnixDomainSocket localUnixDomainSocket = new UnixDomainSocket(paramString, paramBoolean, paramInt1); 48 localUnixDomainSocket.bind(); 153 validateSocketStatusTransition(3); 154 UnixSocketImpl.unStreamSocketBind(this.socketHandle); 155 this.socketStatus = 3; 230 paramInt = i - j; 231 int k = UnixSocketImpl.unStreamSocketWrite(this.socketHandle, paramByteBuffer, j, paramInt); 232 if (k > 0) 326 { 327 str = UnixSocketImpl.unStreamSocketGetNativeInfo(this.socketHandle); 328 } 366 367 private UnixDomainSocket(UnixDomainSocket paramUnixDomainSocket, long paramLong, int paramInt) 368 {WebSocketClientHandshakerFactory.java https://gitlab.com/taichu/netty | Java | 132 lines
21 22import static io.netty.handler.codec.http.websocketx.WebSocketVersion.*; 23 50 public static WebSocketClientHandshaker newHandshaker( 51 URI webSocketURL, WebSocketVersion version, String subprotocol, 52 boolean allowExtensions, HttpHeaders customHeaders) { 74 public static WebSocketClientHandshaker newHandshaker( 75 URI webSocketURL, WebSocketVersion version, String subprotocol, 76 boolean allowExtensions, HttpHeaders customHeaders, int maxFramePayloadLength) { 83 * 84 * @param webSocketURL 85 * URL for web socket communications. e.g "ws://myhost.com/mypath". 106 public static WebSocketClientHandshaker newHandshaker( 107 URI webSocketURL, WebSocketVersion version, String subprotocol, 108 boolean allowExtensions, HttpHeaders customHeaders, int maxFramePayloadLength,mono-logger.c https://github.com/kumpera/mono.git | C | 521 lines
290 { "io-layer-process", MONO_TRACE_IO_LAYER_PROCESS }, 291 { "io-layer-socket", MONO_TRACE_IO_LAYER_SOCKET }, 292 { "io-layer-file", MONO_TRACE_IO_LAYER_FILE }, 299 { "io-layer", MONO_TRACE_IO_LAYER_PROCESS 300 | MONO_TRACE_IO_LAYER_SOCKET 301 | MONO_TRACE_IO_LAYER_FILEserver.js https://gitlab.com/thomasphillips3/beerlocker | JavaScript | 448 lines
48 * @param {(Buffer|string)} [options.sslPass=null] String or buffer containing the certificate password (needs to have a mongod server with ssl support, 2.4 or higher) 49 * @param {object} [options.socketOptions=null] Socket options 50 * @param {boolean} [options.socketOptions.autoReconnect=false] Reconnect on error. 50 * @param {boolean} [options.socketOptions.autoReconnect=false] Reconnect on error. 51 * @param {boolean} [options.socketOptions.noDelay=true] TCP Socket NoDelay option. 52 * @param {number} [options.socketOptions.keepAlive=0] TCP KeepAlive on the socket with a X ms delay before start. 53 * @param {number} [options.socketOptions.connectTimeoutMS=0] TCP Connection timeout setting 54 * @param {number} [options.socketOptions.socketTimeoutMS=0] TCP Socket timeout setting 55 * @param {number} [options.reconnectTries=30] Server attempt to reconnect #times 105 106 // Socket options passed down 107 if(options.socketOptions) { 113 if(options.socketOptions.socketTimeoutMS) { 114 clonedOptions.socketTimeout = options.socketOptions.socketTimeoutMS; 115 }overload2.html https://bitbucket.org/johnny_lai/labvvis.git | HTML | 104 lines
26<div class="titlepage"><div><div><h5 class="title"> 27<a name="boost_asio.reference.basic_raw_socket.receive.overload2"></a><a class="link" href="overload2.html" title="basic_raw_socket::receive (2 of 3 overloads)">basic_raw_socket::receive 28 (2 of 3 overloads)</a> 45<a name="boost_asio.reference.basic_raw_socket.receive.overload2.h0"></a> 46 <span><a name="boost_asio.reference.basic_raw_socket.receive.overload2.parameters"></a></span><a class="link" href="overload2.html#boost_asio.reference.basic_raw_socket.receive.overload2.parameters">Parameters</a> 47 </h6> 62<a name="boost_asio.reference.basic_raw_socket.receive.overload2.h1"></a> 63 <span><a name="boost_asio.reference.basic_raw_socket.receive.overload2.return_value"></a></span><a class="link" href="overload2.html#boost_asio.reference.basic_raw_socket.receive.overload2.return_value">Return 64 Value</a> 70<a name="boost_asio.reference.basic_raw_socket.receive.overload2.h2"></a> 71 <span><a name="boost_asio.reference.basic_raw_socket.receive.overload2.exceptions"></a></span><a class="link" href="overload2.html#boost_asio.reference.basic_raw_socket.receive.overload2.exceptions">Exceptions</a> 72 </h6> 83<a name="boost_asio.reference.basic_raw_socket.receive.overload2.h3"></a> 84 <span><a name="boost_asio.reference.basic_raw_socket.receive.overload2.remarks"></a></span><a class="link" href="overload2.html#boost_asio.reference.basic_raw_socket.receive.overload2.remarks">Remarks</a> 85 </h6>overload2.html https://bitbucket.org/johnny_lai/labvvis.git | HTML | 104 lines
26<div class="titlepage"><div><div><h5 class="title"> 27<a name="boost_asio.reference.basic_datagram_socket.send.overload2"></a><a class="link" href="overload2.html" title="basic_datagram_socket::send (2 of 3 overloads)">basic_datagram_socket::send 28 (2 of 3 overloads)</a> 45<a name="boost_asio.reference.basic_datagram_socket.send.overload2.h0"></a> 46 <span><a name="boost_asio.reference.basic_datagram_socket.send.overload2.parameters"></a></span><a class="link" href="overload2.html#boost_asio.reference.basic_datagram_socket.send.overload2.parameters">Parameters</a> 47 </h6> 62<a name="boost_asio.reference.basic_datagram_socket.send.overload2.h1"></a> 63 <span><a name="boost_asio.reference.basic_datagram_socket.send.overload2.return_value"></a></span><a class="link" href="overload2.html#boost_asio.reference.basic_datagram_socket.send.overload2.return_value">Return 64 Value</a> 70<a name="boost_asio.reference.basic_datagram_socket.send.overload2.h2"></a> 71 <span><a name="boost_asio.reference.basic_datagram_socket.send.overload2.exceptions"></a></span><a class="link" href="overload2.html#boost_asio.reference.basic_datagram_socket.send.overload2.exceptions">Exceptions</a> 72 </h6> 83<a name="boost_asio.reference.basic_datagram_socket.send.overload2.h3"></a> 84 <span><a name="boost_asio.reference.basic_datagram_socket.send.overload2.remarks"></a></span><a class="link" href="overload2.html#boost_asio.reference.basic_datagram_socket.send.overload2.remarks">Remarks</a> 85 </h6>Makefile.in https://bitbucket.org/manctl/stk.git | Autoconf | 104 lines
72 73inetIn: inetIn.cpp Stk.o InetWvIn.o RtWvOut.o RtAudio.o Socket.o TcpServer.o UdpSocket.o Thread.o Mutex.o 74 $(CC) $(LDFLAGS) $(CFLAGS) $(DEFS) -o inetIn inetIn.cpp $(OBJECT_PATH)/Stk.o $(OBJECT_PATH)/InetWvIn.o $(OBJECT_PATH)/Socket.o $(OBJECT_PATH)/TcpServer.o $(OBJECT_PATH)/UdpSocket.o $(OBJECT_PATH)/Thread.o $(OBJECT_PATH)/Mutex.o $(OBJECT_PATH)/RtWvOut.o $(OBJECT_PATH)/RtAudio.o $(LIBRARY) 75 76inetOut: inetOut.cpp Stk.o FileRead.o FileWvIn.o InetWvOut.o Socket.o TcpClient.o UdpSocket.o Thread.o Mutex.o 77 $(CC) $(LDFLAGS) $(CFLAGS) $(DEFS) -o inetOut inetOut.cpp $(OBJECT_PATH)/Stk.o $(OBJECT_PATH)/FileRead.o $(OBJECT_PATH)/FileWvIn.o $(OBJECT_PATH)/Socket.o $(OBJECT_PATH)/TcpClient.o $(OBJECT_PATH)/UdpSocket.o $(OBJECT_PATH)/Thread.o $(OBJECT_PATH)/Mutex.o $(OBJECT_PATH)/InetWvOut.o $(LIBRARY) 90 91controlbee: controlbee.cpp Stk.o FileRead.o FileWvIn.o FileLoop.o FM.o RtAudio.o TwoZero.o SineWave.o ADSR.o BeeThree.o Messager.o RtMidi.o Socket.o TcpServer.o Thread.o Mutex.o Skini.o 92 $(CC) $(LDFLAGS) $(CFLAGS) $(DEFS) -o controlbee controlbee.cpp $(OBJECT_PATH)/Stk.o $(OBJECT_PATH)/FileRead.o $(OBJECT_PATH)/FileWvIn.o $(OBJECT_PATH)/FileLoop.o $(OBJECT_PATH)/FM.o $(OBJECT_PATH)/RtAudio.o $(OBJECT_PATH)/TwoZero.o $(OBJECT_PATH)/SineWave.o $(OBJECT_PATH)/ADSR.o $(OBJECT_PATH)/BeeThree.o $(OBJECT_PATH)/Messager.o $(OBJECT_PATH)/RtMidi.o $(OBJECT_PATH)/Socket.o $(OBJECT_PATH)/TcpServer.o $(OBJECT_PATH)/Thread.o $(OBJECT_PATH)/Mutex.o $(OBJECT_PATH)/Skini.o $(LIBRARY) 96 97threebees: threebees.cpp Stk.o FileRead.o FileWvIn.o FileLoop.o FM.o RtAudio.o TwoZero.o SineWave.o ADSR.o BeeThree.o Messager.o RtMidi.o Socket.o TcpServer.o Thread.o Mutex.o Skini.o Voicer.o 98 $(CC) $(LDFLAGS) $(CFLAGS) $(DEFS) -o threebees threebees.cpp $(OBJECT_PATH)/Stk.o $(OBJECT_PATH)/FileRead.o $(OBJECT_PATH)/FileWvIn.o $(OBJECT_PATH)/FileLoop.o $(OBJECT_PATH)/FM.o $(OBJECT_PATH)/RtAudio.o $(OBJECT_PATH)/TwoZero.o $(OBJECT_PATH)/SineWave.o $(OBJECT_PATH)/ADSR.o $(OBJECT_PATH)/BeeThree.o $(OBJECT_PATH)/Messager.o $(OBJECT_PATH)/RtMidi.o $(OBJECT_PATH)/Socket.o $(OBJECT_PATH)/TcpServer.o $(OBJECT_PATH)/Thread.o $(OBJECT_PATH)/Mutex.o $(OBJECT_PATH)/Skini.o $(OBJECT_PATH)/Voicer.o $(LIBRARY)overload1.html https://bitbucket.org/vaporoid/boost.git | HTML | 94 lines
26<div class="titlepage"><div><div><h5 class="title"> 27<a name="boost_asio.reference.basic_socket_streambuf.shutdown.overload1"></a><a class="link" href="overload1.html" title="basic_socket_streambuf::shutdown (1 of 2 overloads)">basic_socket_streambuf::shutdown 28 (1 of 2 overloads)</a> 44<a name="boost_asio.reference.basic_socket_streambuf.shutdown.overload1.h0"></a> 45 <span class="phrase"><a name="boost_asio.reference.basic_socket_streambuf.shutdown.overload1.parameters"></a></span><a class="link" href="overload1.html#boost_asio.reference.basic_socket_streambuf.shutdown.overload1.parameters">Parameters</a> 46 </h6> 57<a name="boost_asio.reference.basic_socket_streambuf.shutdown.overload1.h1"></a> 58 <span class="phrase"><a name="boost_asio.reference.basic_socket_streambuf.shutdown.overload1.exceptions"></a></span><a class="link" href="overload1.html#boost_asio.reference.basic_socket_streambuf.shutdown.overload1.exceptions">Exceptions</a> 59 </h6> 75 </p> 76<pre class="programlisting"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">asio</span><span class="special">::</span><span class="identifier">ip</span><span class="special">::</span><span class="identifier">tcp</span><span class="special">::</span><span class="identifier">socket</span> <span class="identifier">socket</span><span class="special">(</span><span class="identifier">io_service</span><span class="special">);</span> 77<span class="special">...</span> 77<span class="special">...</span> 78<span class="identifier">socket</span><span class="special">.</span><span class="identifier">shutdown</span><span class="special">(</span><span class="identifier">boost</span><span class="special">::</span><span class="identifier">asio</span><span class="special">::</span><span class="identifier">ip</span><span class="special">::</span><span class="identifier">tcp</span><span class="special">::</span><span class="identifier">socket</span><span class="special">::</span><span class="identifier">shutdown_send</span><span class="special">);</span> 79</pre>core.py https://github.com/mor1/python-xmpp-server.git | Python | 461 lines
36 def __repr__(self): 37 peer = self.stream.socket and self.stream.socket.getpeername() 38 return '<%s %r>' % (type(self).__name__, peer) 267 def use_tls(self): 268 return bool(ssl and self.stream.socket) 269os-win32.h https://gitlab.com/paelzer/qemu | C Header | 213 lines
131 132/* We wrap all the sockets functions so that we can 133 * set errno based on WSAGetLastError() 150#undef socket 151#define socket qemu_socket_wrap 152int qemu_socket_wrap(int domain, int type, int protocol); 163#undef ioctlsocket 164#define ioctlsocket qemu_ioctlsocket_wrap 165int qemu_ioctlsocket_wrap(int fd, int req, void *val); 167#undef closesocket 168#define closesocket qemu_closesocket_wrap 169int qemu_closesocket_wrap(int fd);EcoreController.xtend https://gitlab.com/yeckey/fundus-pyro-demo | Xtend | 159 lines
24 import info.scce.pyro.core.rest.types.CreateEcore; 25 import info.scce.pyro.sync.GraphModelWebSocket; 26 import info.scce.pyro.sync.ProjectWebSocket; 54 @javax.inject.Inject 55 private ProjectWebSocket projectWebSocket; 56 57 @javax.inject.Inject 58 private GraphModelWebSocket graphModelWebSocket; 59 120 PyroProject pp = graphModelController.getProject(folder); 121 projectWebSocket.send(pp.getDywaId(), WebSocketMessage.fromDywaEntity(subject.getDywaId(), info.scce.pyro.core.rest.types.PyroProjectStructure.fromDywaEntity(pp,objectCache))); 122 146 PyroProject pp = graphModelController.getProject(parent); 147 projectWebSocket.send(pp.getDywaId(), WebSocketMessage.fromDywaEntity(subject.getDywaId(), info.scce.pyro.core.rest.types.PyroProjectStructure.fromDywaEntity(pp,objectCache))); 148rdma_user_cm.h https://gitlab.com/oyvholm/linux | C Header | 311 lines
37#include <linux/types.h> 38#include <linux/socket.h> 39#include <linux/in6.h>callback.c https://github.com/Xmister/i5700-leshak-kernel.git | C | 257 lines
84 /* 85 * Listen for a request on the socket 86 */ 163out_err: 164 dprintk("NFS: Couldn't create callback socket or server thread; " 165 "err = %d\n", ret);raw_ip.c https://github.com/amirkrifa/ns-allinone-3.9.git | C | 491 lines
73#include <sys/mbuf.h> 74#include <sys/socket.h> 75#include <sys/protosw.h> 75#include <sys/protosw.h> 76#include <sys/socketvar.h> 77 92/* 93 * Nominal space allocated to a raw ip socket. 94 */ 123 struct inpcb *inp; 124 struct socket *last = 0; 125 151 } 152 last = inp->inp_socket; 153 }README.md https://gitlab.com/dongrvtop/angularcomponent | Markdown | 300 lines
3 4[](https://github.com/socketio/engine.io-client/actions) 5[](http://badge.fury.io/js/engine.io-client) 8the implementation of transport-based cross-browser/cross-device 9bi-directional communication layer for [Socket.IO](http://github.com/socketio/socket.io). 10 67<script> 68 var socket = new eio.Socket('ws://localhost/'); 69 socket.binaryType = 'blob'; 228 - `onlyBinaryUpgrades` (`Boolean`): whether transport upgrades should be restricted to transports supporting binary data (`false`) 229 - `forceNode` (`Boolean`): Uses NodeJS implementation for websockets - even if there is a native Browser-Websocket available, which is preferred by default over the NodeJS implementation. (This is useful when using hybrid platforms like nw.js or electron) (`false`, NodeJS only) 230 - `localAddress` (`String`): the local IP address to connect to 233 - **Websocket-only options** 234 - `protocols` (`Array`): a list of subprotocols (see [MDN reference](https://developer.mozilla.org/en-US/docs/Web/API/WebSockets_API/Writing_WebSocket_servers#Subprotocols)) 235- `send`regress_listener.c https://gitlab.com/storedmirrors/minix | C | 215 lines
35#ifndef WIN32 36#include <sys/socket.h> 37#include <netinet/in.h> 55static void 56acceptcb(struct evconnlistener *listener, evutil_socket_t fd, 57 struct sockaddr *addr, int socklen, void *arg) 61 TT_BLATHER(("Got one for %p", ptr)); 62 evutil_closesocket(fd); 63 81 82 evutil_socket_t fd1 = -1, fd2 = -1, fd3 = -1; 83 118 fd1 = fd2 = fd3 = -1; 119 evutil_socket_connect(&fd1, (struct sockaddr*)&ss1, slen1); 120 evutil_socket_connect(&fd2, (struct sockaddr*)&ss1, slen1);index.js https://gitlab.com/ar2rsawseen/countly-server | JavaScript | 251 lines
19 20 this.onSocket = (s) => { 21 this.socket = s; 24 this.onError = (e) => { 25 log.e('socket error %j', e); 26 }; 42 this.agent = new https.Agent(this.options); 43 this.agent.maxSockets = 1; 44 143 }); 144 req.on('socket', this.onSocket.bind(this)); 145 req.on('error', this.onError.bind(this)); 234 this._closed = true; 235 if (this.socket) { 236 this.socket.emit('agentRemove');ping.c https://gitlab.com/SerenityS/msm8974_G2_render_kernel | C | 230 lines
2 * INET An implementation of the TCP/IP protocol suite for the LINUX 3 * operating system. INET is implemented using the BSD Socket 4 * interface as the means of communication with the user level. 5 * 6 * "Ping" sockets 7 *client.rb https://gitlab.com/alx741/metasploit-framework | Ruby | 219 lines
5 6require 'rex/socket' 7require 'thread' 38 39 self.sock = Rex::Socket::Udp.create( 40 'PeerHost' => self.server_host, 44 45 self.monitor = ::Thread.new { monitor_socket } 46 64 65 def monitor_socket 66 while true 81 rescue ::Exception => e 82 dprint("monitor_socket: #{e.class} #{e} #{e.backtrace}") 83 breaksend.html https://bitbucket.org/drainware/boost.git | HTML | 69 lines
7<link rel="home" href="../../../boost_asio.html" title="Boost.Asio"> 8<link rel="up" href="../basic_raw_socket.html" title="basic_raw_socket"> 9<link rel="prev" href="reuse_address.html" title="basic_raw_socket::reuse_address"> 22<div class="spirit-nav"> 23<a accesskey="p" href="reuse_address.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_raw_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="send/overload1.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a> 24</div> 26<div class="titlepage"><div><div><h4 class="title"> 27<a name="boost_asio.reference.basic_raw_socket.send"></a><a class="link" href="send.html" title="basic_raw_socket::send">basic_raw_socket::send</a> 28</h4></div></div></div> 36 <span class="keyword">const</span> <span class="identifier">ConstBufferSequence</span> <span class="special">&</span> <span class="identifier">buffers</span><span class="special">);</span> 37 <span class="emphasis"><em>» <a class="link" href="send/overload1.html" title="basic_raw_socket::send (1 of 3 overloads)">more...</a></em></span> 38 40 <span class="keyword">typename</span> <a class="link" href="../ConstBufferSequence.html" title="Constant buffer sequence requirements">ConstBufferSequence</a><span class="special">></span> 41<span class="identifier">std</span><span class="special">::</span><span class="identifier">size_t</span> <a class="link" href="send/overload2.html" title="basic_raw_socket::send (2 of 3 overloads)">send</a><span class="special">(</span> 42 <span class="keyword">const</span> <span class="identifier">ConstBufferSequence</span> <span class="special">&</span> <span class="identifier">buffers</span><span class="special">,</span>TrustingOkHttpClient.java https://gitlab.com/samuel-davis/DDF-TestSource | Java | 175 lines
23import javax.net.ssl.SSLSession; 24import javax.net.ssl.SSLSocketFactory; 25import javax.net.ssl.TrustManager; 84 // Create an ssl socket factory with our all-trusting manager 85 final SSLSocketFactory sslSocketFactory = sslContext.getSocketFactory(); 86 88 89 builder.sslSocketFactory(sslSocketFactory); 90control.hpp https://gitlab.com/vectorci/rippled | C++ Header | 182 lines
10 * documentation and/or other materials provided with the distribution. 11 * * Neither the name of the WebSocket++ Project nor the 12 * names of its contributors may be used to endorse or promote products 27 28#ifndef WEBSOCKET_CONTROL_MESSAGE_HPP 29#define WEBSOCKET_CONTROL_MESSAGE_HPP 34#include "../processors/processor.hpp" 35#include "../websocket_frame.hpp" 36#include "../utf8_validator/utf8_validator.hpp" 38 39using websocketpp_02::processor::hybi_util::circshift_prepared_key; 40 40 41namespace websocketpp_02 { 42namespace message {AwsIotMqttConnection.java https://gitlab.com/github-cloud-corp/aws-iot-device-sdk-java | Java | 170 lines
46 47 private final SocketFactory socketFactory; 48 53 54 public AwsIotMqttConnection(AbstractAwsIotClient client, SocketFactory socketFactory, String serverUri) 55 throws AWSIotException { 57 58 this.socketFactory = socketFactory; 59 146 147 private MqttConnectOptions buildMqttConnectOptions(AbstractAwsIotClient client, SocketFactory socketFactory) { 148 MqttConnectOptions options = new MqttConnectOptions(); 149 150 options.setSocketFactory(socketFactory); 151 options.setCleanSession(true);sandbox.c https://gitlab.com/0072016/Facebook-SDK- | C | 483 lines
24#include <sys/resource.h> 25#include <sys/socket.h> 26#include <sys/stat.h> 82 int sv[2]; 83 if (socketpair(AF_UNIX, SOCK_STREAM, 0, sv) == -1) { 84 perror("socketpair"); 232 // We need to close kZygoteIdFd before the child can continue. We use this 233 // socketpair to tell the child when to continue; 234 int sync_fds[2]; 234 int sync_fds[2]; 235 if (socketpair(AF_UNIX, SOCK_STREAM, 0, sync_fds)) { 236 FatalError("Failed to create a socketpair"); 248 if (close(sync_fds[0]) || shutdown(sync_fds[1], SHUT_RD)) 249 FatalError("Could not close socketpair"); 250 // The kZygoteIdFd needs to be closed in the parent beforepcap-bpf.c https://bitbucket.org/__wp__/mb-linux-msli.git | C | 263 lines
28#include <sys/timeb.h> 29#include <sys/socket.h> 30#include <sys/file.h>acconfig.h https://bitbucket.org/__wp__/mb-linux-msli.git | C Header | 288 lines
157 158/* MIT pthreads does not support connecting with unix sockets */ 159#undef HAVE_THREADS_WITHOUT_SOCKETS 229/* Define as the base type of the last arg to accept */ 230#undef SOCKET_SIZE_TYPE 231config.h https://bitbucket.org/__wp__/mb-linux-msli.git | C Header | 253 lines
181 182/* Define if you have the socket function. */ 183#define HAVE_SOCKET 1cardbus.c https://bitbucket.org/__wp__/mb-linux-msli.git | C | 252 lines
86 cards. The "result" that is used externally is the cb_cis_virt 87 pointer in the struct pcmcia_socket structure. 88 90 91static void cb_release_cis_mem(struct pcmcia_socket * s) 92{ 100 101static int cb_setup_cis_mem(struct pcmcia_socket * s, struct resource *res) 102{ 129 130int read_cb_mem(struct pcmcia_socket * s, int space, u_int addr, u_int len, void *ptr) 131{ 209 210int __ref cb_alloc(struct pcmcia_socket * s) 211{netlogon.c https://bitbucket.org/mikedep333/rdssamba4.git | C | 200 lines
24#include "nbt_server/nbt_server.h" 25#include "lib/socket/socket.h" 26#include <ldb.h> 40 struct nbt_dgram_packet *packet, 41 const struct socket_address *src, 42 struct nbt_netlogon_packet *netlogon) 94 struct nbt_dgram_packet *packet, 95 const struct socket_address *src, 96 struct nbt_netlogon_packet *netlogon) 106 if (!my_ip) { 107 DEBUG(0, ("Could not obtain own IP address for datagram socket\n")); 108 return; 149 struct nbt_dgram_packet *packet, 150 struct socket_address *src) 151{namespace.test.js https://bitbucket.org/jesperrasmussen/slides.git | JavaScript | 286 lines
53 }) 54 .on('connection', function (socket) { 55 cl.end(); 96 cl.handshake(function (sid) { 97 ws = websocket(cl, sid); 98 ws.on('open', function () { 116 }) 117 .on('connection', function (socket) { 118 throw new Error('Should not be called'); 256 257 io.sockets.on('connection', function (socket) { 258 socket.on('foobar', function () { 263 cl.handshake(function (sid) { 264 ws = websocket(cl, sid); 265shepherd.scm https://gitlab.com/janneke/guix | Scheme | 157 lines
102 (format #f "/run/user/~a" (getuid))) 103 "/shepherd/socket")) 104 (let ((log-dir (or (getenv "XDG_LOG_HOME") 128 (format #f "/run/user/~a" (getuid))) 129 "/shepherd/socket")) 130 #$(reload-configuration-gexp config)simple-error-model.cc https://gitlab.com/pmaddi/cs433 | C++ | 173 lines
115 116 OnOffHelper onoff ("ns3::UdpSocketFactory", 117 Address (InetSocketAddress (i3i2.GetAddress (1), port))); 125 // Create an optional packet sink to receive these packets 126 PacketSinkHelper sink ("ns3::UdpSocketFactory", 127 Address (InetSocketAddress (Ipv4Address::GetAny (), port))); 133 onoff.SetAttribute ("Remote", 134 AddressValue (InetSocketAddress (i1i2.GetAddress (0), port))); 135 apps = onoff.Install (c.Get (3)); 140 sink.SetAttribute ("Local", 141 AddressValue (InetSocketAddress (Ipv4Address::GetAny (), port))); 142 apps = sink.Install (c.Get (1));Makefile https://github.com/vincentcoetzee/ecl-iphone.git | Makefile | 412 lines
42# TCP support 43ECL_SOCKETS = 44# X Windows support 154!endif 155!ifdef ECL_SOCKETS 156ECL_MODULES = $(ECL_MODULES) sockets 156ECL_MODULES = $(ECL_MODULES) sockets 157ECL_FEATURES = (cons :wants-sockets $(ECL_FEATURES)) 158!endifeventtarget.rs https://gitlab.com/0072016/0072016-SDK-js-sdk-framework- | Rust | 349 lines
51 Node(NodeTypeId), 52 WebSocket, 53 Window,Cocos2dxHttpURLConnection.java https://gitlab.com/gasabr/flappy-test | Java | 403 lines
131 132 httpsURLConnection.setSSLSocketFactory(context.getSocketFactory()); 133 } catch (Exception e) {sendserver.c https://gitlab.com/brian0218/rk3066_r-box_android4.2.2_sdk | C | 520 lines
234 235 sockfd = socket (AF_INET, SOCK_DGRAM, 0); 236 if (sockfd < 0) 238 memset (secret, '\0', sizeof (secret)); 239 error("rc_send_server: socket: %s", strerror(errno)); 240 return (ERROR_RC);tcp.c https://bitbucket.org/altlc/wive-rtnl-ralink-rt305x-routers-firmware-amod.git | C | 311 lines
51*/ 52RC_TYPE tcp_destruct(TCP_SOCKET *p_self) 53{ 107 { 108 p_self->super.socket = socket(AF_INET, SOCK_STREAM, 0); 109 if (p_self->super.socket == -1) 110 { 111 int code = os_get_socket_error(); 112 128 logit(LOG_WARNING, MODULE_TAG "Failed binding client socket to local address: %s", strerror(code)); 129 rc = RC_IP_SOCKET_BIND_ERROR; 130 break; 143 setsockopt(p_self->super.socket, SOL_SOCKET, SO_RCVTIMEO, &sv, svlen); 144 setsockopt(p_self->super.socket, SOL_SOCKET, SO_SNDTIMEO, &sv, svlen); 145i4b_q932fac.c https://github.com/kame/kame.git | C | 573 lines
55#include <sys/mbuf.h> 56#include <sys/socket.h> 57#include <net/if.h>