PageRenderTime 26ms queryFilters 2ms Sphinxql 60ms app.CodeModel.GetByIds 16ms findMatchingLines 64ms GetByIds 80ms meta 0ms repositoryFilters 11ms languageFilters 1ms sourceFilters 5ms

626,242 results for 'socket repo:hwo2014/hwo2014-team-1496' (26 ms)

Source

Language

Repository

dllmain.c https://bitbucket.org/arty/arty-newcc-reactos | C | 3,026 lines
554    {
555        SocketListHead = SocketListHead->NextSocket;
556    }
563            {
564                CurrentSocket->NextSocket = CurrentSocket->NextSocket->NextSocket;
565                break;
567
568            CurrentSocket = CurrentSocket->NextSocket;
569        }
1331
1332    AcceptSocket = WSPSocket (Socket->SharedData.AddressFamily,
1333                              Socket->SharedData.SocketType,
2469
2470        CurrentSocket = CurrentSocket->NextSocket;
2471    }
server_select.lua https://bitbucket.org/jefferai/prosody | Lua | 936 lines
58local luasec = use "ssl"
59local luasocket = use "socket" or require "socket"
60
480			bufferlen = 0
481			_sendlistlen = removesocket( _sendlist, socket, _sendlistlen ) -- delete socket from writelist
482			_ = needtls and handler:starttls(nil, true)
551			local err
552			socket, err = ssl_wrap( socket, sslctx )	-- wrap socket
553			if err then
578				local oldsocket, err = socket
579				socket, err = ssl_wrap( socket, sslctx )	-- wrap socket
580				--out_put( "server.lua: sslwrapped socket is " .. tostring( socket ) )
654
655removesocket = function( list, socket, len )	-- this function removes sockets from a list ( copied from copas )
656	local pos = list[ socket ]
test_socket.py https://bitbucket.org/l0nwlf/policy-and-header-refactor | Python | 1,495 lines
31    def setUp(self):
32        self.serv = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
33        self.port = support.bind_port(self.serv)
42    def setUp(self):
43        self.serv = socket.socket(socket.AF_INET, socket.SOCK_DGRAM)
44        self.port = support.bind_port(self.serv)
235    def test_weakref(self):
236        s = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
237        p = proxy(s)
502        port = self._get_unused_port()
503        sock = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
504        sock.bind(("0.0.0.0", port))
1449        time.sleep(0.1)
1450        self.cli = socket.socket(socket.AF_TIPC, socket.SOCK_STREAM)
1451        addr = (socket.TIPC_ADDR_NAME, TIPC_STYPE,
socket.rst https://bitbucket.org/l0nwlf/policy-and-header-refactor | Unknown | 895 lines
631
632   Send data to the socket.  The socket must be connected to a remote socket.  The
633   optional *flags* argument has the same meaning as for :meth:`recv` above.
640
641   Send data to the socket.  The socket must be connected to a remote socket.  The
642   optional *flags* argument has the same meaning as for :meth:`recv` above.
772   PORT = 50007              # Arbitrary non-privileged port
773   s = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
774   s.bind((HOST, PORT))
790   PORT = 50007              # The same port as used by the server
791   s = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
792   s.connect((HOST, PORT))
880   # create a raw socket and bind it to the public interface
881   s = socket.socket(socket.AF_INET, socket.SOCK_RAW, socket.IPPROTO_IP)
882   s.bind((HOST, 0))
Socket.h https://bitbucket.org/rosselm/projects | C++ Header | 611 lines
53	/// Socket is the common base class for
54	/// StreamSocket, ServerSocket, DatagramSocket and other
55	/// socket classes.
72
73	Socket(const Socket& socket);
74		/// Copy constructor.
78		
79	Socket& operator = (const Socket& socket);
80		/// Assignment operator.
112
113	static int select(SocketList& readList, SocketList& writeList, SocketList& exceptList, const Poco::Timespan& timeout);
114		/// Determines the status of one or more sockets, 
320//
321inline bool Socket::operator == (const Socket& socket) const
322{
socket.rst https://bitbucket.org/habnabit/mont-e | Unknown | 921 lines
663
664   Send data to the socket.  The socket must be connected to a remote socket.  The
665   optional *flags* argument has the same meaning as for :meth:`recv` above.
673
674   Send data to the socket.  The socket should not be connected to a remote socket,
675   since the destination socket is specified by *address*.  The optional *flags*
798   PORT = 50007              # Arbitrary non-privileged port
799   s = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
800   s.bind((HOST, PORT))
816   PORT = 50007              # The same port as used by the server
817   s = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
818   s.connect((HOST, PORT))
906   # create a raw socket and bind it to the public interface
907   s = socket.socket(socket.AF_INET, socket.SOCK_RAW, socket.IPPROTO_IP)
908   s.bind((HOST, 0))
net.tex https://bitbucket.org/mischief/oskit | Unknown | 1,025 lines
35
36\apiintf{oskit_socket}{Socket Interface}
37
118
119    A socket factory is an instance of the \texttt{oskit_socket_factory}
120    COM interface.  Implementations of this interface will be provided
894    % Open file descriptors are now passed as ancillary data for AF_UNIX domain
895    % sockets, with cmsg_level set to SOL_SOCKET and cmsg_type set to
896    % SCM_RIGHTS.
931        \funcproto oskit_error_t
932	oskit_socket_sendto(oskit_socket_t *s, 
933		    const void *buf,
940        \funcproto oskit_error_t
941        oskit_socket_sendmsg(oskit_socket_t *s,
942                    const struct oskit_msghdr *msg, 
NetUtils.java https://bitbucket.org/hadoop/hadoop-0.21.0 | Java | 464 lines
127   */
128  public static InetSocketAddress createSocketAddr(String target) {
129    return createSocketAddr(target, -1);
288    return (socket.getChannel() == null) ? 
289          socket.getInputStream() : new SocketInputStream(socket, timeout);
290  }
339    return (socket.getChannel() == null) ? 
340            socket.getOutputStream() : new SocketOutputStream(socket, timeout);            
341  }
359   */
360  public static void connect(Socket socket, 
361                             SocketAddress endpoint, 
366    
367    SocketChannel ch = socket.getChannel();
368    
telnet.cpp https://bitbucket.org/luxrender/luxrays | C++ | 918 lines
62		for (;;) {
63			tcp::socket socket(ioService);
64			acceptor.accept(socket);
70				respStream << "SmallLuxGPU Telnet Server Interface\n";
71				boost::asio::write(socket, response);
72
75					// Print prompt
76					boost::asio::write(socket, boost::asio::buffer("> ", 2));
77
79					boost::asio::streambuf commandBuf;
80					boost::asio::read_until(socket, commandBuf, "\n");
81
174								respStream << "OK\n";
175								boost::asio::write(socket, response);
176							} else {
socket.c https://bitbucket.org/zossso/android-kernel-2.6.34-motus | C | 3,153 lines
1/*
2 * NET		An implementation of the SOCKET network access protocol.
3 *
29 *					allowed to allocate.
30 *		Linus		:	Argh. removed all the socket allocation
31 *					altogether: it's in the inode now.
278{
279	struct socket_alloc *ei = (struct socket_alloc *)foo;
280
1219		if (net_ratelimit())
1220			printk(KERN_WARNING "socket: no more sockets\n");
1221		return -ENFILE;	/* Not exactly a match, but its the
3028
3029int kernel_accept(struct socket *sock, struct socket **newsock, int flags)
3030{
yenta_socket.c https://bitbucket.org/zossso/android-kernel-2.6.34-motus | C | 1,470 lines
213{
214	struct yenta_socket *socket = container_of(sock, struct yenta_socket, socket);
215	unsigned int val;
405{
406	struct yenta_socket *socket = container_of(sock, struct yenta_socket, socket);
407	int map;
442{
443	struct yenta_socket *socket = container_of(sock, struct yenta_socket, socket);
444	struct pci_bus_region region;
554
555	yenta_set_socket(&socket->socket, &dead_socket);
556	for (i = 0; i < 2; i++) {
601{
602	struct yenta_socket *socket = container_of(sock, struct yenta_socket, socket);
603
test_core.py git://github.com/gabrielfalcao/HTTPretty.git | Python | 666 lines
172
173def test_fake_ssl_socket_proxies_its_ow_socket():
174    ("FakeSSLSocket is a simpel wrapper around its own socket, "
289@patch('httpretty.core.old_socket')
290def test_fakesock_socket_real_sendall(old_socket):
291    ("fakesock.socket#real_sendall calls truesock#connect and bails "
356@patch('httpretty.core.socket')
357def test_fakesock_socket_real_sendall_continue_eagain_when_http(socket, old_socket):
358    ("fakesock.socket#real_sendall should continue if the socket error was EAGAIN")
392@patch('httpretty.core.socket')
393def test_fakesock_socket_real_sendall_socket_error_when_http(socket, old_socket):
394    ("fakesock.socket#real_sendall should continue if the socket error was EAGAIN")
590    # Given an instance of that socket
591    socket = MySocket()
592    socket._entry = entry
sockets.constants.html https://github.com/tsujita/dotfiles.git | HTML | 2,237 lines
8 <body><div class="manualnavbar" style="text-align: center;">
9 <div class="prev" style="text-align: left; float: left;"><a href="sockets.resources.html">リソース型</a></div>
10 <div class="next" style="text-align: right; float: right;"><a href="sockets.examples.html">例</a></div>
10 <div class="next" style="text-align: right; float: right;"><a href="sockets.examples.html">例</a></div>
11 <div class="up"><a href="book.sockets.html">ソケット</a></div>
12 <div class="home"><a href="index.html">PHP Manual</a></div>
12 <div class="home"><a href="index.html">PHP Manual</a></div>
13</div><hr /><div id="sockets.constants" class="appendix">
14 <h1>定義済み定数</h1>
443
444  <dt id="constant.sol-socket">
445   <span class="term">
698    <span class="simpara">
699     Socket operation on non-socket.
700    </span>
library.dylan git://github.com/dylan-lang/opendylan.git | Unknown | 3,836 lines
685    g-socket-listener-close,
686    g-socket-listener-add-socket,
687    g-socket-listener-add-inet-port,
738    g-socket-connection-is-connected,
739    g-socket-connection-get-socket,
740    g-socket-connection-get-remote-address,
780    g-socket-client-set-timeout,
781    g-socket-client-set-socket-type,
782    g-socket-client-set-protocol,
788    g-socket-client-get-timeout,
789    g-socket-client-get-socket-type,
790    g-socket-client-get-protocol,
871    g-socket-get-timeout,
872    g-socket-get-socket-type,
873    g-socket-get-remote-address,
ws_SUITE.erl https://github.com/fgallaire/cowboy.git | Erlang | 710 lines
107	{port, Port} = lists:keyfind(port, 1, Config),
108	{ok, Socket} = gen_tcp:connect("localhost", Port,
109		[binary, {active, false}, {packet, raw}]),
109		[binary, {active, false}, {packet, raw}]),
110	ok = gen_tcp:send(Socket,
111		"GET /ws_echo_timer HTTP/1.1\r\n"
113		"Connection: Upgrade\r\n"
114		"Upgrade: WebSocket\r\n"
115		"Origin: http://localhost\r\n"
115		"Origin: http://localhost\r\n"
116		"Sec-Websocket-Key1: Y\" 4 1Lj!957b8@0H756!i\r\n"
117		"Sec-Websocket-Key2: 1711 M;4\\74  80<6\r\n"
118		"\r\n"),
119	{ok, Handshake} = gen_tcp:recv(Socket, 0, 6000),
120	{ok, {http_response, {1, 1}, 400, _}, _}
socketmodule.c https://bitbucket.org/cwalther/cwe-ou-nobink | C | 4,152 lines
28- socket.getservbyname(servicename, protocolname) --> port number
29- socket.socket([family[, type [, proto]]]) --> new socket object
30- socket.ntohs(16 bit value) --> new int object
36- socket.getnameinfo(sockaddr, flags) --> (host, port)
37- socket.AF_INET, socket.SOCK_STREAM, etc.: constants from <socket.h>
38- socket.has_ipv6: boolean value indicating if IPv6 is supported
2229{
2230	PySocketSockObject *s = (PySocketSockObject *)self;
2231	SOCKET_T fd;
3494	PyModule_AddObject(m, "error", socket_error);
3495	socket_herror = PyErr_NewException("socket.herror",
3496					   socket_error, NULL);
3500	PyModule_AddObject(m, "herror", socket_herror);
3501	socket_gaierror = PyErr_NewException("socket.gaierror", socket_error,
3502	    NULL);
test_ssl.py https://bitbucket.org/pombredanne/cpython | Python | 2,036 lines
642            # this should fail because we have no verification certs
643            s = ssl.wrap_socket(socket.socket(socket.AF_INET),
644                                cert_reqs=ssl.CERT_REQUIRED)
649            # this should succeed because we specify the root cert
650            s = ssl.wrap_socket(socket.socket(socket.AF_INET),
651                                cert_reqs=ssl.CERT_REQUIRED,
738            # Same with a server hostname
739            s = ctx.wrap_socket(socket.socket(socket.AF_INET),
740                                server_hostname="svn.python.org")
782            ctx.load_verify_locations(capath=BYTES_CAPATH)
783            s = ctx.wrap_socket(socket.socket(socket.AF_INET))
784            s.connect(("svn.python.org", 443))
864            s.connect(remote)
865            s = ssl.wrap_socket(socket.socket(socket.AF_INET),
866                                cert_reqs=ssl.CERT_NONE, ciphers="DEFAULT")
test_socket.py https://bitbucket.org/pombredanne/cpython | Python | 4,863 lines
47    try:
48        s = socket.socket(socket.PF_CAN, socket.SOCK_RAW, socket.CAN_RAW)
49    except (AttributeError, OSError):
124    def setUp(self):
125        self.s = socket.socket(socket.PF_CAN, socket.SOCK_RAW, socket.CAN_RAW)
126        self.addCleanup(self.s.close)
1292    def testBindAny(self):
1293        with socket.socket(socket.PF_CAN, socket.SOCK_RAW, socket.CAN_RAW) as s:
1294            s.bind(('', ))
1304    def testLoopback(self):
1305        with socket.socket(socket.PF_CAN, socket.SOCK_RAW, socket.CAN_RAW) as s:
1306            for loopback in (0, 1):
1316        can_filter = struct.pack("=II", can_id, can_mask)
1317        with socket.socket(socket.PF_CAN, socket.SOCK_RAW, socket.CAN_RAW) as s:
1318            s.setsockopt(socket.SOL_CAN_RAW, socket.CAN_RAW_FILTER, can_filter)
socket.rst https://bitbucket.org/pombredanne/cpython | Unknown | 1,409 lines
1209   PORT = 50007              # Arbitrary non-privileged port
1210   s = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
1211   s.bind((HOST, PORT))
1227   PORT = 50007              # The same port as used by the server
1228   s = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
1229   s.connect((HOST, PORT))
1317   # create a raw socket and bind it to the public interface
1318   s = socket.socket(socket.AF_INET, socket.SOCK_RAW, socket.IPPROTO_IP)
1319   s.bind((HOST, 0))
1355   # create a raw socket and bind it to the 'vcan0' interface
1356   s = socket.socket(socket.AF_CAN, socket.SOCK_RAW, socket.CAN_RAW)
1357   s.bind(('vcan0',))
1384
1385   s = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
1386   s.setsockopt(socket.SOL_SOCKET, socket.SO_REUSEADDR, 1)
socket.io.js git://github.com/LearnBoost/socket.io.git | JavaScript | 2,459 lines
220        request('http://localhost:54020')
221        .get('/socket.io/socket.io.js')
222        .expect(200, done);
2177  describe('middleware', function(done){
2178    var Socket = require('../lib/socket');
2179
2184      sio.use(function(socket, next){
2185        expect(socket).to.be.a(Socket);
2186        run++;
2189      sio.use(function(socket, next){
2190        expect(socket).to.be.a(Socket);
2191        run++;
2367  describe('socket middleware', function(done){
2368    var Socket = require('../lib/socket');
2369
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21