| Commit message (Collapse) | Author | Age |
... | |
|
|
|
|
|
|
|
|
|
| |
Find the real name of the tty using ttyname_r(3) instead of
opening "/dev/tty" which causes trouble if the fd doesn't point to the
controlling terminal.
PR-URL: https://github.com/libuv/libuv/pull/779
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Saúl Ibarra Corretgé <saghul@gmail.com>
|
|
|
|
|
|
|
|
|
|
|
| |
This commit adds the uv_get_passwd() function, which returns a
subset of the current effective user's password file entry.
Refs: https://github.com/libuv/libuv/issues/11
Fixes: https://github.com/libuv/libuv/issues/731
PR-URL: https://github.com/libuv/libuv/pull/742
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Saúl Ibarra Corretgé <saghul@gmail.com>
|
|
|
|
|
|
|
|
|
| |
Make explicit that handles and requests should be closed before calling
uv_loop_close().
Fixes: https://github.com/libuv/libuv/issues/765
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Saúl Ibarra Corretgé <saghul@gmail.com>
|
|
|
|
|
|
|
|
|
|
|
| |
It allows detecting the remote socket closing the connection. It's
emitted when `EPOLLRDHUP`(Linux), `EV_EOF`(BSD), `POLLRDHUP`(Solaris,
AIX) and `AFD_POLL_DISCONNECT`(Windows) events are received.
PR-URL: https://github.com/libuv/libuv/pull/691
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Fedor Indutny <fedor@indutny.com>
Reviewed-By: Saúl Ibarra Corretgé <saghul@gmail.com>
|
|
|
|
|
|
|
|
|
| |
If an API function returns UV_ENOBUFS make sure we count the terminating
null, which we need space for. In case of success the null byte is not
included in the count, but the buffer *is* null terminated.
PR-URL: https://github.com/libuv/libuv/pull/690
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
|
|
|
|
|
| |
PR-URL: https://github.com/libuv/libuv/pull/734
Reviewed-By: Saúl Ibarra Corretgé <saghul@gmail.com>
|
|
|
|
|
| |
PR-URL: https://github.com/libuv/libuv/pull/672
Reviewed-By: Saúl Ibarra Corretgé <saghul@gmail.com>
|
|
|
|
|
|
|
|
| |
Equivalent to realpath(3), returns the full resolved absolute path of a
file or directory.
PR-URL: https://github.com/libuv/libuv/pull/531
Reviewed-By: Saúl Ibarra Corretgé <saghul@gmail.com>
|
|
|
|
|
| |
PR-URL: https://github.com/libuv/libuv/pull/291
Reviewed-By: Saúl Ibarra Corretgé <saghul@gmail.com>
|
|
|
|
|
|
|
|
| |
I think this makes it clear that the flags can't contain any other
information.
PR-URL: https://github.com/libuv/libuv/pull/592
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
|
|
|
|
|
|
|
|
| |
Signed-off-by: Eli Skeggs <skeggse@gmail.com>
Fixes: https://github.com/libuv/libuv/issues/181
PR-URL: https://github.com/libuv/libuv/pull/520
Reviewed-By: Saúl Ibarra Corretgé <saghul@gmail.com>
|
|
|
|
|
| |
PR-URL: https://github.com/libuv/libuv/pull/509
Reviewed-By: Saúl Ibarra Corretgé <saghul@gmail.com>
|
|
|
|
|
| |
PR-URL: https://github.com/libuv/libuv/pull/503
Reviewed-By: Saúl Ibarra Corretgé <saghul@gmail.com>
|
|
|
|
|
| |
PR-URL: https://github.com/libuv/libuv/pull/500
Reviewed-By: Saúl Ibarra Corretgé <saghul@gmail.com>
|
|
|
|
|
|
|
|
|
|
|
|
| |
Make uv_err_name() and uv_strerror() return a dynamically allocated
string when the error code is not recognized.
It leaks a few bytes of memory but that can't be helped. Asserting
and aborting is, in my opinion, much less helpful.
Fixes: https://github.com/nodejs/node/issues/63
PR-URL: https://github.com/libuv/libuv/pull/467
Reviewed-By: Saúl Ibarra Corretgé <saghul@gmail.com>
|
|
|
|
|
| |
PR-URL: https://github.com/libuv/libuv/pull/478
Reviewed-By: Saúl Ibarra Corretgé <saghul@gmail.com>
|
|
|
|
|
| |
On Linux getting the type is only supported by some filesystems, check
getdents(2).
|
|
|
|
|
| |
PR-URL: https://github.com/libuv/libuv/pull/432
Reviewed-By: Saúl Ibarra Corretgé <saghul@gmail.com>
|
|
|
|
|
|
|
|
|
| |
Original patch by @ghostoy, modified by @bpasero and yours truly.
Refs: https://github.com/joyent/libuv/pull/1473
Refs: https://github.com/libuv/libuv/pull/198
PR-URL: https://github.com/libuv/libuv/pull/421
Reviewed-By: Bert Belder <bertbelder@gmail.com>
|
|
|
|
|
|
|
|
| |
The '.' and '..' entries are always skipped on Unix systems.
Refs: https://github.com/libuv/libuv/issues/426
PR-URL: https://github.com/libuv/libuv/pull/427
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Introduce two new APIs:
int uv_tcp_init_ex(uv_loop_t*, uv_tcp_t* handle, int flags)
int uv_udp_init_ex(uv_loop_t*, uv_udp_t* handle, int flags)
The lower 8 bits of the flags field are used for the socket domain.
AF_INET, AF_INET6 and AF_UNSPEC are supported. If AF_UNSPEC is specified
the socket is created lazily, just like uv_{tcp,udp}_init.
Some Windows notes:
getsockname fails with WSAEINVAL if the socket is not bound. This could
potentially be improved by detecting the socket family and filling
the sockaddr_in/6 struct manually.
bind returns WSAEFAULT if we try to bind a socket to the wrong family.
Unix returns EINVAL.
PR-URL: https://github.com/libuv/libuv/pull/400
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
|
|
|
|
|
|
|
|
|
|
| |
The previous Windows implementation used SHGetKnownFolderPath(),
which is only supported on Vista and up. This commit switches to
GetUserProfileDirectoryW(), which returns the same information,
but is supported back to Windows 2000, and is not deprecated.
PR-URL: https://github.com/libuv/libuv/pull/375
Reviewed-By: Saúl Ibarra Corretgé <saghul@gmail.com>
|
|
|
|
|
|
|
|
|
|
|
|
| |
This patch is composed by the work done in
https://github.com/libuv/libuv/pull/231 and
https://github.com/libuv/libuv/pull/287 plus some changes by yours
truly.
Thanks @beevik and @mattsta for their work on this!
PR-URL: https://github.com/libuv/libuv/pull/368
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
|
|
|
|
|
|
| |
PR-URL: https://github.com/libuv/libuv/pull/350
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Saúl Ibarra Corretgé <saghul@gmail.com>
|
|
|
|
|
| |
PR-URL: https://github.com/libuv/libuv/pull/355
Reviewed-By: Saúl Ibarra Corretgé <saghul@gmail.com>
|
|
|
|
|
|
|
|
| |
Saying uv_run() always returns zero is incorrect in the presence of
calls to uv_stop().
PR-URL: https://github.com/libuv/libuv/pull/337
Reviewed-By: Saúl Ibarra Corretgé <saghul@gmail.com>
|
|
|
|
|
|
| |
This reverts commit c272f1f1bc0bda625e6441d798c110b4064a6ce2.
The concept will come back to libuv, but it needs some more work.
|
|
|
|
|
| |
PR-URL: https://github.com/libuv/libuv/pull/332
Reviewed-By: Saúl Ibarra Corretgé <saghul@gmail.com>
|
|
|
|
|
| |
PR-URL: https://github.com/libuv/libuv/pull/307
Reviewed-By: Saúl Ibarra Corretgé <saghul@gmail.com>
|
|
|
|
|
|
| |
Fixes: https://github.com/libuv/libuv/issues/281
PR-URL: https://github.com/libuv/libuv/pull/284
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
|
|
|
|
|
|
|
|
|
|
| |
Reject file descriptors that correspond to regular files or char/block
devices. Such file descriptors are incompatible with epoll and trigger
a run-time assert.
Fixes: https://github.com/libuv/libuv/issues/255
PR-URL: https://github.com/libuv/libuv/pull/259
Reviewed-By: Saúl Ibarra Corretgé <saghul@gmail.com>
|
|
|
|
|
| |
PR-URL: https://github.com/libuv/libuv/pull/259
Reviewed-By: Saúl Ibarra Corretgé <saghul@gmail.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
With uv_replace_allocator, it's possible to override the default
memory allocator's malloc and free calls with functions of the user's
choosing. This allows libuv to interoperate with projects requiring a
custom memory allocator.
Internally, all calls to malloc and free have been replaced with
uv__malloc and uv__free, respectively. The uv__malloc and uv__free
functions call malloc and free unless they have been overridden by a
previous call to uv_replace_allocator.
As part of this change, the special aligned memory allocations
performed in src/win/fs-event.c have been replaced with standard
allocations. The 4-byte alignment being requested in this file was
unnecessary, since standard allocators already guarantee at least an
8-byte alignment.
PR-URL: https://github.com/libuv/libuv/pull/231
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Saúl Ibarra Corretgé <saghul@gmail.com>
|
|
|
|
|
|
| |
Fixes: https://github.com/libuv/libuv/issues/182
PR-URL: https://github.com/libuv/libuv/pull/233
Reviewed-By: Tim Caswell <tim@creationix.com>
|
|
|
|
|
| |
PR-URL: https://github.com/libuv/libuv/pull/236
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
|
|
|
|
|
| |
PR-URL: https://github.com/libuv/libuv/pull/236
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
|
|
|
|
|
| |
PR-URL: https://github.com/libuv/libuv/pull/227
Reviewed-By: Saúl Ibarra Corretgé <saghul@gmail.com>
|
| |
|
|
|
|
|
|
|
|
|
| |
Before this commit, UNIX returned -1 on failure. Windows sometimes
returned a UV_E* error code and sometimes a bogus status code, courtesy
of errno values not mapping to UV_E* error codes on that platform.
PR-URL: https://github.com/libuv/libuv/pull/204
Reviewed-By: Saúl Ibarra Corretgé <saghul@gmail.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Commit 393c1c5 ("unix: set non-block mode in uv_{pipe,tcp,udp}_open")
causes a regression in the io.js cluster module.
The io.js documentation states that `worker.send()` and `process.send()`
are synchronous but they no longer were after upgrading to libuv v1.2.1.
The reason they are synchronous is because of backpressure - or rather,
lack of backpressure: a slow consumer eventually causes a fast producer
to run out of memory because the backlog of pending messages in the
producer can grow unchecked.
Ergo, implement uv_stream_set_blocking() on UNIX platforms to let io.js
enable the old blocking behavior for pipes again.
Refs: https://github.com/iojs/io.js/issues/760
PR-URL: https://github.com/libuv/libuv/pull/187
Reviewed-By: Saúl Ibarra Corretgé <saghul@gmail.com>
|
|
|
|
|
| |
PR-URL: https://github.com/libuv/libuv/pull/166
Reviewed-By: Saúl Ibarra Corretgé <saghul@gmail.com>
|
|
|
|
|
| |
PR-URL: https://github.com/libuv/libuv/pull/159
Reviewed-By: Saúl Ibarra Corretgé <saghul@gmail.com>
|
|
|
|
|
|
|
|
|
|
| |
uv_fs_poll_getpath, uv_pipe_getsockname, uv_fs_event_getpath used
to return the trailing null terminator, even though the functions
returned the size.
Fixes: https://github.com/libuv/libuv/issues/155
PR-URL: https://github.com/libuv/libuv/pull/159
Reviewed-By: Saúl Ibarra Corretgé <saghul@gmail.com>
|
|
|
|
|
|
| |
PR-URL: https://github.com/libuv/libuv/pull/156
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Bert Belder <bertbelder@gmail.com>
|
|
|
|
|
|
|
|
| |
Indicate that it can (and should) also be closed, currently it's not
"special" in any way.
PR-URL: https://github.com/libuv/libuv/pull/147
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
|
|
|
|
|
|
|
|
|
|
|
| |
Add an explanation about how libuv implements the threadpool and why.
This is so users know what behavior they should expect when they make
use of threads.
Related issue: https://github.com/libuv/libuv/issues/145
PR-URL: https://github.com/libuv/libuv/pull/146
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
|
|
|
|
|
| |
PR-URL: https://github.com/libuv/libuv/pull/135
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
|
|
|
|
|
|
|
|
|
|
|
|
| |
libuv requires that the socket/fd is in non-blocking mode, so do it
internally so the user doesn't need to write platform specific code to
do so.
This also makes the API consistent with uv_{tcp,udp,pipe}_open, since
it's not required to pass the fd in non-blocking mode there either.
PR-URL: https://github.com/libuv/libuv/pull/136
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
|