- Aug 30, 2012
-
-
Bert Belder authored
-
- Aug 25, 2012
-
-
Ben Noordhuis authored
Some memory was leaked when the uv_udp_t handle was closed when there were in-flight send requests with a heap allocated buffer list. That doesn't happen much in practice. In the common case (writing < 5 buffers), the buffer list is stored inside the uv_udp_send_t structure, not allocated on the heap.
-
- Aug 22, 2012
-
-
Ben Noordhuis authored
-
- Aug 20, 2012
-
-
Bert Belder authored
uv_update_time does not overwrite the high 32 bits of uv_loop_t.time. It merely increments it by one when the low 32 bits have wrapped. That means that `time` needs to be initialized to zero before uv_update_time() is called for the first time.
-
Ben Noordhuis authored
uv_fs_poll_t has an embedded uv_timer_t handle that got closed at a time when the memory of the encapsulating handle might already have been deallocated. Solve that by moving the poller's state into a structure that is allocated on the heap and can be freed independently.
-
Ben Noordhuis authored
-
Ben Noordhuis authored
This is a back-port of commit f97c80fa from the master branch.
-
- Aug 18, 2012
-
-
Tim Holy authored
Conversion to nanoseconds was overflowing with 32-bit builds.
-
- Aug 16, 2012
-
-
Ben Noordhuis authored
kstat_data_lookup("clock_Mhz") returns a KSTAT_DATA_INT32 on i386 but a KSTAT_DATA_INT64 on x86_64.
-
- Aug 15, 2012
-
-
Ben Noordhuis authored
-
- Aug 13, 2012
-
-
Ben Noordhuis authored
Make the gcc_version macro conform with what node.js and v8 use. Important because node.js's common.gypi is going to export it soon.
-
- Aug 08, 2012
-
-
Bert Belder authored
Ref: joyent/node#3779
-
Bert Belder authored
-
- Aug 03, 2012
-
-
Bert Belder authored
This improves uv_getaddrinfo error reporting.
-
- Jul 31, 2012
-
-
Bert Belder authored
-
Bert Belder authored
This is closer to the Posix model.
-
Bert Belder authored
This shouldn't be necessary, but node v0.8 relies on it.
-
Bert Belder authored
Hopefully this fixes joyent/node#3779.
-
Bert Belder authored
-
Bert Belder authored
* It's now more efficient, the file is not opened twice. * It no longer allows deletion of non-symlink directory reparse points.
-
Bert Belder authored
Old and new path were accidentally reversed.
-
Ben Noordhuis authored
This is a back-port of commit cfb06db5 from the master branch. Fixes joyent/node#3768.
-
- Jul 30, 2012
-
-
Ben Noordhuis authored
-
Bert Belder authored
Also clean up the code in various ways.
-
Bert Belder authored
-
- Jul 28, 2012
-
-
Ben Noordhuis authored
Problem: registering two uv_fs_event_t watchers for the same path, then closing them, caused a segmentation fault. While active, the watchers didn't work right either, only one would receive events. Cause: each watcher has a wd (watch descriptor) that's used as its key in a binary tree. When you call inotify_watch_add() twice with the same path, the second call doesn't return a new wd - it returns the existing one. That in turn resulted in the first handle getting ousted from the binary tree, leaving dangling pointers. This commit addresses that by storing the watchers in a queue and storing the queue in the binary tree instead of storing the watchers directly in the tree. Fixes joyent/node#3789.
-
Ben Noordhuis authored
-
Ben Noordhuis authored
-
Ben Noordhuis authored
Watches the same file twice. Fails on Linux with a segmentation fault.
-
- Jul 25, 2012
-
-
Shuhei Tanuma authored
Fixes #500.
-
- Jul 19, 2012
-
-
Ben Noordhuis authored
uv_set_process_title() was susceptible to a format string vulnerability: $ node -e 'process.title = Array(42).join("%s")' Segmentation fault: 11 (core dumped) The fix is trivial - call setproctitle("%s", s) instead of setproctitle(s) - but valgrind complains loudly about reads from and writes to uninitialized memory in libc. It's not a libuv bug because the test case below triggers the same warnings: #include <sys/types.h> #include <unistd.h> int main(void) { setproctitle("%s", "test"); return 0; } That's why this commit replaces setproctitle() with sysctl(KERN_PROC_ARGS). This commit reapplies commit a9f6f06f, which got reverted in 69a6afea. The revert turned out to be unnecessary.
-
Ben Noordhuis authored
Don't create a new socket descriptor if one has been previously assigned with uv_pipe_open().
-
Ben Noordhuis authored
Remember the errno when the socket() syscall fails.
-
- Jul 18, 2012
-
-
Ben Noordhuis authored
It's making node.js crash when run as root. Backtrace: (gdb) bt #0 0x00007fff856e3ff9 in __findenv () #1 0x00007fff856e404c in getenv () #2 0x000000010004c850 in loop_init (loop=0x10045a792, flags=8) at ev.c:1707 #3 0x000000010004cb3b in ev_backend [inlined] () at /Users/tjfontaine/Development/node/deps/uv/src/unix/ev/ev.c:2090 #4 0x000000010004cb3b in ev_default_loop (flags=1606417108) at ev.c:2092 #5 0x000000010004e5c6 in uv__loop_init (loop=0x10066e330, default_loop=1) at loop.c:52 #6 0x0000000100044367 in uv_default_loop () at core.c:196 #7 0x0000000100004625 in node::Init (argc=1606417456, argv=0x100b0f490) at node.cc:2761 #8 0x000000010000797d in node::Start (argc=1606417600, argv=0x0) at node.cc:2888 #9 0x0000000100000ca4 in start () This reverts commits: b49d6f7c unix: fix uv_set_process_title() a9f6f06f unix: fix format string vulnerability in freebsd.c a87abc70 unix: avoid buffer overflow in proctitle.c dc97d44c unix: move uv_set_process_title() to proctitle.c
-
- Jul 17, 2012
-
-
Ben Noordhuis authored
Use strncpy() to set the process title, it pads the remainder with nul bytes. Avoids garbage output on systems where `ps aux` prints the entire proctitle buffer, not just the characters up to the first '\0'. Fixes joyent/node#3726.
-
- Jul 13, 2012
-
-
Ben Noordhuis authored
uv_set_process_title() was susceptible to a format string vulnerability: $ node -e 'process.title = Array(42).join("%s")' Segmentation fault: 11 (core dumped) The fix is trivial - call setproctitle("%s", s) instead of setproctitle(s) - but valgrind complains loudly about reads from and writes to uninitialized memory in libc. It's not a libuv bug because the test case below triggers the same warnings: #include <stdio.h> #include <stdlib.h> #include <sys/types.h> #include <unistd.h> int main(void) { setproctitle("%s", "test"); return 0; } That's why this commit replaces setproctitle() with sysctl(KERN_PROC_ARGS).
-
Ben Noordhuis authored
Get/set process title with uv_strlcpy(), not strncpy(). The latter won't zero-terminate the result if the destination buffer is too small.
-
Fedor Indutny authored
Use hijacking argv array to change process' title. It seems to be working fine on almost every platform (at least it should not break anything as it's used in nginx in a similar way).
-
- Jul 10, 2012
-
-
Fedor Indutny authored
-
- Jul 04, 2012
-
-
Ben Noordhuis authored
-