Commit Graph

2681 Commits

Author SHA1 Message Date
Lars Gierth
cd67e10ece build: update android toolchain
gcc-4.7 has been removed in revision r9c. More info:
http://developer.android.com/tools/sdk/ndk/index.html#Revisions
2014-02-21 18:54:52 +01:00
Lars Gierth
1ad61807ff test: fix spawn_stdout_and_stderr_to_file test
S_IREAD and S_IWRITE are obsolete in GNU libs and
not included in the Android NDK's libc. See
http://www.gnu.org/savannah-checkouts/gnu/libc
/manual/html_node/Permission-Bits.html
2014-02-21 18:54:52 +01:00
Oleg Efimov
da9a2b1d3d unix, windows: add uv_getrusage() function 2014-02-21 18:50:15 +01:00
Saúl Ibarra Corretgé
787f5fff92 unix, windows: add uv_loop_init and uv_loop_close
These functions supersede uv_loop_new and uv_loop_delete.
uv_loop_init initialized a user allocated loop and uv_loop_close
removes all associated resources a loop uses after it has finished
execution.

uv_loop_new and uv_loop_delete are now deprecated.
2014-02-21 09:56:13 +01:00
William Light
bfba45d285 linux: include grp.h for setgroups() 2014-02-20 15:53:48 +01:00
Rasmus Pedersen
fd35e7a0bd test: fix VC++ warning C4244 2014-02-20 11:32:07 +01:00
Geoffry Song
780d8ad8e5 linux: always deregister closing fds from epoll
If the same file description is open in two different processes, then
closing the file descriptor is not sufficient to deregister it from the
epoll instance (as described in epoll(7)), resulting in spurious events
that cause the event loop to spin repeatedly. So always explicitly
deregister it.

Fixes #1099.
2014-02-19 17:13:49 +04:00
Ben Noordhuis
f17c535b73 unix: use a heap for timers
Replace the red-black tree with a heap.  The most common operation that
libuv performs on timers is looking up the first timer to expire.  With
a red-black tree, that operation is O(log n).  With a heap, it's O(1).
2014-02-19 13:36:14 +01:00
Fedor Indutny
fc40836f9a Merge branch 'v0.10'
Conflicts:
	src/unix/sunos.c
2014-02-19 00:18:25 +04:00
Fedor Indutny
703a9e601e sunos: handle rearm errors
fix #1078
2014-02-19 00:14:13 +04:00
Bert Belder
d9872ae2ad Merge branch 'v0.10'
Conflicts:
	build.mk
	test/test-shutdown-twice.c
2014-02-18 19:19:52 +01:00
Alexis Campailla
4f913b669a windows: freeze in uv_tcp_endgame
The event_handle field of unused accept requests was not being
initialized properly. As a result, uv_tcp_endgame would try to close
an invalid handle and this could lead to unexpected behavior.

This fixes node.js test test-cluster-disconnect.js on Windows.
2014-02-18 19:16:47 +01:00
Fedor Indutny
a03ea239db Revert "fs: vectored IO API for filesystem read/write"
This reverts commit 7df24583e5.
2014-02-18 21:48:13 +04:00
Timothy J Fontaine
3310ff4a9e build: update dtrace m4 check for sunos
The check to see if -G is needed for dtrace requires a bit more effort,
make a header, c file, and object file.
2014-02-18 07:31:05 -08:00
Saúl Ibarra Corretgé
d7c8cffecb windows: fixed compilation warning 2014-02-18 11:35:01 +01:00
Marc Schlaich
8010bf9dd2 build, windows: fixed x64 configuration issue 2014-02-18 10:02:05 +01:00
Benjamin Saunders
7df24583e5 fs: vectored IO API for filesystem read/write
This improves API consistency with uv_read and uv_write and may
improve efficiency for some uses. Vectored IO is emulated when the
requisite system calls are unavailable.
2014-02-18 12:30:20 +04:00
Saúl Ibarra Corretgé
d4c12adff6 include: expose libuv version in header files 2014-02-17 20:53:20 +01:00
Alex Crichton
6f62d62c90 windows: always initialize uv_process_t
The unix implementation of uv_spawn always starts out with a
uv__handle_init, but the windows implementation sometimes bails out
early before calling uv__handle_init. This means that uv_close on a
failed uv_spawn will always succeed on unix but sometimes fail on
windows.

This commit lifts the initialization of the uv_process_t above all of
the error checking to ensure that uv_close will always work when
uv_spawn returns an error.
2014-02-16 13:09:54 +01:00
Alex Crichton
8692bbc254 windows: fix building on MinGW
The crtdbg.h header was added in c0716b3d, but MinGW does not have this
header present on the system. This commit takes the same approach of
2684f876a and just ignores this header and functionality on MinGW
2014-02-16 13:02:02 +01:00
Saúl Ibarra Corretgé
6e2021ca11 unix: correct error when calling uv_shutdown twice
This is a backport of a284b90 for v0.10 branch
2014-02-15 16:55:06 +01:00
Keno Fischer
a284b90c03 unix: correct error when calling uv_shutdown twice
Before this one of the requests was left as a ghost in the system.
See https://github.com/JuliaLang/julia/issues/5793
2014-02-15 16:37:58 +01:00
Saúl Ibarra Corretgé
107be2bed3 unix, windows: map EFBIG errno 2014-02-14 17:03:19 +01:00
Saúl Ibarra Corretgé
c8e4db6e00 include: mark close_cb field as private 2014-02-11 23:56:50 +01:00
Brian White
b738d315fb build: skip vcvarsall if already set up
Without this, running vcbuild repeatedly for some time will cause errors with msbuild saying the command line is too long (due to concatenation happening in vcvarsall).
2014-02-10 23:13:35 +01:00
Saúl Ibarra Corretgé
66ab38918c unix: call setgoups before calling setuid/setgid
Partial fix for #1093
2014-02-10 22:38:40 +01:00
Saúl Ibarra Corretgé
3901ec4976 unix: fix uv_tcp_nodelay return value in case of error
Fixes #1102
2014-02-10 09:00:46 +01:00
Saúl Ibarra Corretgé
419c2ffae7 test: fix udp multicast interface test 2014-02-10 08:56:39 +01:00
Sam Roberts
a3c0e48faa doc: describe signal send emulation on windows
Signals don't exist on Windows, but libuv emulates the behaviour of
several Unix signals. This wasn't documented, and the existing
documentation for signal reception emulation on Windows was worded as if
it applied to signal sending, which it does not.
2014-02-07 09:39:06 +01:00
Austin Foxley
451de61b72 unix, win: add uv_udp_set_multicast_interface() 2014-02-07 09:07:11 +01:00
Fedor Indutny
7301d21e46 gyp: qualify library variable
Use prefixed variable name for better control over dependencies.
2014-02-05 21:29:25 +04:00
Fedor Indutny
280469f4fe test: build spawn_fs_open only on unixes 2014-02-05 13:35:37 +04:00
Dylan Cali
60d621c607 gitignore: root test ignores at /test 2014-02-03 20:49:38 +04:00
Fedor Indutny
cb1cc25430 test: fix build on windows
disable spawn_fs_open
2014-02-01 04:57:16 +04:00
Fedor Indutny
6abe1e4b95 fs: uv__cloexec() opened fd
Every file descriptor opened using libuv should be automatically marked
as CLOEXEC to prevent it from leaking to a child process. Note that
since we are opening fds in a thread pool, there is a possible race
condition between `uv_spawn()` and the `open()` + `uv__cloexec()`. The
rwlock was added to avoid it.

see https://github.com/joyent/node/issues/6905
2014-02-01 01:02:37 +04:00
Dylan Cali
6c525df76d test: set getaddrinfo_fail timeout to 10000
getaddrinfo_fail can sometimes take slightly longer than the default
timeout of 5000. Set its timeout to 10000 to compensate, but leave the
timeout of all other tests at the default.
2014-02-01 00:50:40 +04:00
Dylan Cali
756087e017 test: support flexibly setting custom task options
Add a single TEST_ENTRY_CUSTOM hook that can be used to override task
entry defaults. Different tests can have different timeouts depending on
what is appropriate for each test. A separate TEST_OUTPUT_ENTRY hook is
no longer necessary.

In order to support per-task timeouts, the timeout field has been moved
into the task_entry_t struct. The default (5000) is now set as part of
TEST_ENTRY.
2014-02-01 00:50:40 +04:00
Fedor Indutny
513ce625ba Merge branch 'v0.10'
Conflicts:
	AUTHORS
	ChangeLog
	src/unix/stream.c
	src/version.c
2014-01-31 20:59:49 +04:00
Oguz Bastemur
a6ff04d2c4 stream: start thread after assignments
Changed the order of the member assignments since the thread
may start before the parameters are assigned. This especially
happens when the osx scheduler is very busy.
2014-01-31 20:53:06 +04:00
Timothy J Fontaine
b0ec132aab Now working on v0.11.20 2014-01-29 09:43:38 -08:00
Timothy J Fontaine
336a182530 2014.01.30, Version 0.11.19 (Unstable)
Changes since version 0.11.18:

* linux: move sscanf() out of the assert() (Trevor Norris)

* linux: fix C99/C++ comment (Fedor Indutny)
2014-01-29 09:43:38 -08:00
Timothy J Fontaine
79ffe2fb95 Now working on v0.10.25 2014-01-29 09:41:41 -08:00
Timothy J Fontaine
aecd296b6b 2014.01.30, Version 0.10.24 (Stable)
Changes since version 0.10.23:

* linux: move sscanf() out of the assert() (Trevor Norris)

* linux: fix C99/C++ comment (Fedor Indutny)
2014-01-29 09:41:36 -08:00
Fedor Indutny
923e4ec619 Merge branch 'v0.10'
Conflicts:
	ChangeLog
	src/unix/linux-core.c
	src/version.c
2014-01-29 17:02:25 +04:00
Fedor Indutny
3e2446d18d linux: fix C99/C++ comment 2014-01-29 17:01:35 +04:00
Trevor Norris
7c8ff3bc25 linux: move sscanf() out of the assert()
If asserts are turned off then the sscanf() wouldn't have run, being
placed directly in the assert() itself.
2014-01-29 17:01:26 +04:00
Bert Belder
666aa2f068 Now working on v0.11.19 2014-01-22 21:37:37 +01:00
Bert Belder
d47962e9d9 2014.01.23, Version 0.11.18 (Unstable)
Changes since version 0.11.17:

* osx: Fix a possible segfault in uv__io_poll (Alex Crichton)

* windows: improved handling of invalid FDs (Alexis Campailla)

* doc: adding ARCHS flag to OS X build command (Nathan Sweet)

* tcp: reveal bind-time errors before listen (Alexis Campailla)

* tcp: uv_tcp_dualstack() (Fedor Indutny)

* linux: relax assumption on /proc/stat parsing (Luca Bruno)

* openbsd: fix obvious bug in uv_cpu_info (Fedor Indutny)

* process: close stdio after dup2'ing it (Fedor Indutny)

* linux: move sscanf() out of the assert() (Trevor Norris)
2014-01-22 21:37:34 +01:00
Bert Belder
278b58df20 Merge tag 'v0.10.23'
Conflicts:
	AUTHORS
	src/version.c
2014-01-22 21:33:46 +01:00
Bert Belder
a568ed6278 authors: add two addresses to .mailmap, fix their name in AUTHORS 2014-01-22 21:27:03 +01:00