Commit Graph

77 Commits

Author SHA1 Message Date
Ben Noordhuis
4ba03ddd56 unix, windows: rename uv_run2 to uv_run
This changes the prototype of uv_run() from:

  int uv_run(uv_loop_t* loop);

To:

  int uv_run(uv_loop_t* loop, uv_run_mode mode);

Where `mode` is UV_RUN_DEFAULT, UV_RUN_ONCE or UV_RUN_NOWAIT.

Fixes #683.
2013-01-16 23:35:29 +01:00
Ben Noordhuis
b8aa5b9bf2 test: don't assert on UV_EPIPE in echo-server.c
UV_EPIPE is not an error per se, it simply indicates that the other end of the
connection - i.e. the test case - has gone away.

Pro-actively ignore UV_ECANCELED errors. They're not actually emitted right now
because there's only ever one pending write but let's be forward compatible.
2012-11-01 15:39:11 +01:00
Ben Noordhuis
57ee146985 test: unlink UNIX socket before starting pipe echo server 2012-04-18 02:39:33 +02:00
Ben Noordhuis
dc3b80a50f test: add udp4_echo_server helper 2012-01-14 00:11:43 +01:00
Ryan Dahl
6921d2fc07 Add argument to uv_pipe_init for IPC, unix impl 2011-10-06 10:17:07 -07:00
Erick Tryzelaar
533418d4da test and bench: assert return values of *_init functions in tests 2011-09-15 22:33:48 +02:00
Bert Belder
0dc564a2aa Remove uv_init calls from tests and benchmarks 2011-09-12 11:32:41 -07:00
Bert Belder
8e3a8602ad update tests for multiplicity 2011-08-31 04:19:26 +02:00
Bert Belder
3aec77f9d4 bring back uv_init 2011-08-31 04:19:07 +02:00
Ryan Dahl
56dcaf9b06 unix: multiplicity 2011-08-31 04:18:55 +02:00
Ben Noordhuis
36ce74f2ca Add UDP support to libuv. 2011-08-24 04:55:01 +02:00
Ryan Dahl
ac1ce29ad0 Improve pound benchmark by reconnecting in close_cb 2011-08-18 15:30:34 -07:00
Ryan Dahl
e5a938f1f4 Add uv_buf_init() constructor 2011-08-17 17:43:19 -07:00
Igor Zinkovsky
23e9ecb667 fix memory leak in echo server 2011-08-11 18:19:59 -07:00
Bert Belder
2d40e35b7e Style 2011-08-12 02:43:59 +02:00
Igor Zinkovsky
a706a66d81 accept benchmark 2011-08-05 18:20:06 -07:00
Igor Zinkovsky
e7497227bd merge uv_tcp_listen and uv_pipe_listen into uv_listen 2011-07-22 16:57:09 -07:00
Ben Noordhuis
4eff34da43 uv-unix: pipes API implementation
Based on UNIX sockets to avoid the vagaries of FIFOs
in asynchronous mode. Currently unlinks stale sockets
before binding and cleans them up again after shutdown.
2011-07-19 00:58:02 +02:00
Ryan Dahl
abe0b1ea61 Better request API
Instead of uv_shutdown, uv_write, uv_connect taking raw uv_req_t we subclass
uv_req_t into uv_shutdown_t, uv_write_t, and uv_connect_t.

uv_req_init is removed.
2011-07-14 10:45:28 -07:00
Igor Zinkovsky
f5ff869488 allocate windows pipe handles on demand 2011-07-13 20:43:10 -07:00
Bert Belder
4c2d0545fc Whitespace fixes 2011-07-14 03:00:21 +02:00
Igor Zinkovsky
2e49cc56d1 Rename uv_pipe_create to uv_pipe_bind.
Fixes issue #97.
2011-07-11 15:24:35 -07:00
Igor Zinkovsky
b6a6dae34f Named pipes implementation for Windows 2011-07-09 21:41:04 +02:00
Robert Mustacchi
8c00b369b4 C99 compatibility.
Get 99% of the way there for --std=c89 -pedantic for core files. Also cleans
up follow up warnings and others in tests.
2011-07-07 21:39:08 -07:00
Ryan Dahl
ce8ff3031c src/ and include/ directories
Helps #71 but does not update the MSVC files.
2011-07-07 07:52:57 -07:00
Henry Rawas
a4b05abce6 optional IPv6 for echo-server 2011-07-06 17:07:37 -07:00
Henry Rawas
26880b0c90 win: IPv6 connect 2011-07-05 09:45:57 -07:00
Igor Zinkovsky
320057d588 uv_stream_t 2011-07-01 05:28:02 -07:00
Ryan Dahl
aabe56b680 uv_tcp_init() must be called before uv_accept()
Windows broken.
2011-06-09 23:33:33 +02:00
Ryan Dahl
b3863c8051 nread should have type ssize_t 2011-06-09 19:45:19 +02:00
Ryan Dahl
04b6aaeb44 API Change: Move close_cb to uv_close from init functions 2011-06-08 05:44:22 -07:00
Ryan Dahl
7db9629f87 API Change: Remove data parameters from init functions 2011-06-08 05:43:02 -07:00
Bert Belder
cfca30433f API change: report accept errors to connection_cb 2011-06-07 18:11:43 +02:00
Ryan Dahl
903c07bf98 API Change: uv_close only called by user - never automatically
Add test that failing on_connect callback does not trigger on_close.
2011-06-03 02:49:55 -07:00
Ryan Dahl
7770b1a1f6 API change: alloc_cb moved to uv_read_start()
Fixes #47.
2011-06-03 02:30:00 -07:00
Ryan Dahl
6b07791598 API Change: Pass sockaddr_in by value instead of reference 2011-06-03 02:19:35 -07:00
Ryan Dahl
11a4ad50c8 Separate out uv_handle_t into different types
Fixes #4
2011-06-03 11:03:52 +02:00
Ryan Dahl
982a620f1c Echo server gracefully dies on 'Q'
Allows for better clean up during tests.
2011-05-27 02:11:43 -07:00
Ryan Dahl
2b8812ffe1 uv_buf -> uv_buf_t 2011-05-13 07:15:02 -07:00
Ryan Dahl
2ef3c6c632 oio -> uv 2011-05-11 20:21:49 -07:00
Ryan Dahl
8f9ff78413 oio_err -> oio_err_t 2011-05-09 02:30:11 -07:00
Ryan Dahl
ba31e8d0fa Add _t to typedef structs 2011-05-08 02:40:39 -07:00
Bert Belder
850e4072e7 tests & benchmarks - make internal stuff static 2011-05-08 03:28:28 +02:00
Bert Belder
0d28b9e549 Echo server should shutdown instead of close 2011-05-04 03:59:35 +02:00
Bert Belder
773b0dcf79 Remove trailing whitespace 2011-05-04 00:41:49 +02:00
Ryan Dahl
17c568b235 unix: fix tcp-writealot 2011-05-03 13:28:56 -07:00
Bert Belder
7124fc5eca Updated echo-server 2011-05-03 21:30:09 +02:00
Bert Belder
d553776f5d Fix echo-server and test-ping-pong 2011-05-03 02:55:51 +02:00
Bert Belder
1a76881cb0 Yet another oio_read api. Hopefully this one sticks. 2011-05-03 00:31:22 +02:00
Bert Belder
5bcbc31920 Tests / benchmarks use new error handling api 2011-04-20 22:34:21 +02:00