diff options
Diffstat (limited to 'deps/uv/docs')
-rw-r--r-- | deps/uv/docs/src/check.rst | 2 | ||||
-rw-r--r-- | deps/uv/docs/src/errors.rst | 6 | ||||
-rw-r--r-- | deps/uv/docs/src/fs.rst | 12 | ||||
-rw-r--r-- | deps/uv/docs/src/fs_event.rst | 2 | ||||
-rw-r--r-- | deps/uv/docs/src/idle.rst | 2 | ||||
-rw-r--r-- | deps/uv/docs/src/index.rst | 1 | ||||
-rw-r--r-- | deps/uv/docs/src/misc.rst | 11 | ||||
-rw-r--r-- | deps/uv/docs/src/pipe.rst | 4 | ||||
-rw-r--r-- | deps/uv/docs/src/signal.rst | 2 | ||||
-rw-r--r-- | deps/uv/docs/src/stream.rst | 4 | ||||
-rw-r--r-- | deps/uv/docs/src/tcp.rst | 13 | ||||
-rw-r--r-- | deps/uv/docs/src/tty.rst | 6 | ||||
-rw-r--r-- | deps/uv/docs/src/udp.rst | 11 | ||||
-rw-r--r-- | deps/uv/docs/src/version.rst | 60 |
14 files changed, 110 insertions, 26 deletions
diff --git a/deps/uv/docs/src/check.rst b/deps/uv/docs/src/check.rst index 8d48f22276..36c93cf03d 100644 --- a/deps/uv/docs/src/check.rst +++ b/deps/uv/docs/src/check.rst @@ -31,7 +31,7 @@ N/A API --- -.. c:function:: int uv_check_init(uv_loop_t*, uv_check_t* check) +.. c:function:: int uv_check_init(uv_loop_t* loop, uv_check_t* check) Initialize the handle. diff --git a/deps/uv/docs/src/errors.rst b/deps/uv/docs/src/errors.rst index 5d59dc30f2..cec25f5187 100644 --- a/deps/uv/docs/src/errors.rst +++ b/deps/uv/docs/src/errors.rst @@ -322,8 +322,10 @@ API .. c:function:: const char* uv_strerror(int err) - Returns the error message for the given error code. + Returns the error message for the given error code. Leaks a few bytes + of memory when you call it with an unknown error code. .. c:function:: const char* uv_err_name(int err) - Returns the error name for the given error code. + Returns the error name for the given error code. Leaks a few bytes + of memory when you call it with an unknown error code. diff --git a/deps/uv/docs/src/fs.rst b/deps/uv/docs/src/fs.rst index c2a3fc252a..33c04406f1 100644 --- a/deps/uv/docs/src/fs.rst +++ b/deps/uv/docs/src/fs.rst @@ -168,6 +168,11 @@ API Equivalent to :man:`open(2)`. + .. note:: + On Windows libuv uses `CreateFileW` and thus the file is always opened + in binary mode. Because of this the O_BINARY and O_TEXT flags are not + supported. + .. c:function:: int uv_fs_read(uv_loop_t* loop, uv_fs_t* req, uv_file file, const uv_buf_t bufs[], unsigned int nbufs, int64_t offset, uv_fs_cb cb) Equivalent to :man:`preadv(2)`. @@ -206,6 +211,13 @@ API get `ent` populated with the next directory entry data. When there are no more entries ``UV_EOF`` will be returned. + .. note:: + Unlike `scandir(3)`, this function does not return the "." and ".." entries. + + .. note:: + On Linux, getting the type of an entry is only supported by some filesystems (btrfs, ext2, + ext3 and ext4 at the time of this writing), check the :man:`getdents(2)` man page. + .. c:function:: int uv_fs_stat(uv_loop_t* loop, uv_fs_t* req, const char* path, uv_fs_cb cb) .. c:function:: int uv_fs_fstat(uv_loop_t* loop, uv_fs_t* req, uv_file file, uv_fs_cb cb) .. c:function:: int uv_fs_lstat(uv_loop_t* loop, uv_fs_t* req, const char* path, uv_fs_cb cb) diff --git a/deps/uv/docs/src/fs_event.rst b/deps/uv/docs/src/fs_event.rst index 681ae52f95..c2d7f52023 100644 --- a/deps/uv/docs/src/fs_event.rst +++ b/deps/uv/docs/src/fs_event.rst @@ -88,7 +88,7 @@ API `path` for changes. `flags` can be an ORed mask of :c:type:`uv_fs_event_flags`. .. note:: Currently the only supported flag is ``UV_FS_EVENT_RECURSIVE`` and - only on OSX. + only on OSX and Windows. .. c:function:: int uv_fs_event_stop(uv_fs_event_t* handle) diff --git a/deps/uv/docs/src/idle.rst b/deps/uv/docs/src/idle.rst index 81f51d2076..1f51c4a19e 100644 --- a/deps/uv/docs/src/idle.rst +++ b/deps/uv/docs/src/idle.rst @@ -39,7 +39,7 @@ N/A API --- -.. c:function:: int uv_idle_init(uv_loop_t*, uv_idle_t* idle) +.. c:function:: int uv_idle_init(uv_loop_t* loop, uv_idle_t* idle) Initialize the handle. diff --git a/deps/uv/docs/src/index.rst b/deps/uv/docs/src/index.rst index 9cdc494aec..fa89c4bffe 100644 --- a/deps/uv/docs/src/index.rst +++ b/deps/uv/docs/src/index.rst @@ -68,6 +68,7 @@ Documentation design errors + version loop handle request diff --git a/deps/uv/docs/src/misc.rst b/deps/uv/docs/src/misc.rst index 9708c5dea4..e9ddba3db6 100644 --- a/deps/uv/docs/src/misc.rst +++ b/deps/uv/docs/src/misc.rst @@ -135,17 +135,6 @@ API For :man:`isatty(3)` equivalent functionality use this function and test for ``UV_TTY``. -.. c:function:: unsigned int uv_version(void) - - Returns the libuv version packed into a single integer. 8 bits are used for - each component, with the patch number stored in the 8 least significant - bits. E.g. for libuv 1.2.3 this would return 0x010203. - -.. c:function:: const char* uv_version_string(void) - - Returns the libuv version number as a string. For non-release versions - "-pre" is appended, so the version number could be "1.2.3-pre". - .. c:function:: int uv_replace_allocator(uv_malloc_func malloc_func, uv_realloc_func realloc_func, uv_calloc_func calloc_func, uv_free_func free_func) .. versionadded:: 1.6.0 diff --git a/deps/uv/docs/src/pipe.rst b/deps/uv/docs/src/pipe.rst index df896a0583..d33b0f2b97 100644 --- a/deps/uv/docs/src/pipe.rst +++ b/deps/uv/docs/src/pipe.rst @@ -29,12 +29,12 @@ N/A API --- -.. c:function:: int uv_pipe_init(uv_loop_t*, uv_pipe_t* handle, int ipc) +.. c:function:: int uv_pipe_init(uv_loop_t* loop, uv_pipe_t* handle, int ipc) Initialize a pipe handle. The `ipc` argument is a boolean to indicate if this pipe will be used for handle passing between processes. -.. c:function:: int uv_pipe_open(uv_pipe_t*, uv_file file) +.. c:function:: int uv_pipe_open(uv_pipe_t* handle, uv_file file) Open an existing file descriptor or HANDLE as a pipe. diff --git a/deps/uv/docs/src/signal.rst b/deps/uv/docs/src/signal.rst index 21675945fc..dc1223b90a 100644 --- a/deps/uv/docs/src/signal.rst +++ b/deps/uv/docs/src/signal.rst @@ -62,7 +62,7 @@ Public members API --- -.. c:function:: int uv_signal_init(uv_loop_t*, uv_signal_t* signal) +.. c:function:: int uv_signal_init(uv_loop_t* loop, uv_signal_t* signal) Initialize the handle. diff --git a/deps/uv/docs/src/stream.rst b/deps/uv/docs/src/stream.rst index 880f0e2ebc..21562b3702 100644 --- a/deps/uv/docs/src/stream.rst +++ b/deps/uv/docs/src/stream.rst @@ -123,7 +123,7 @@ API .. note:: `server` and `client` must be handles running on the same loop. -.. c:function:: int uv_read_start(uv_stream_t*, uv_alloc_cb alloc_cb, uv_read_cb read_cb) +.. c:function:: int uv_read_start(uv_stream_t* stream, uv_alloc_cb alloc_cb, uv_read_cb read_cb) Read data from an incoming stream. The callback will be made several times until there is no more data to read or :c:func:`uv_read_stop` is called. @@ -142,6 +142,8 @@ API Stop reading data from the stream. The :c:type:`uv_read_cb` callback will no longer be called. + This function is idempotent and may be safely called on a stopped stream. + .. c:function:: int uv_write(uv_write_t* req, uv_stream_t* handle, const uv_buf_t bufs[], unsigned int nbufs, uv_write_cb cb) Write data to stream. Buffers are written in order. Example: diff --git a/deps/uv/docs/src/tcp.rst b/deps/uv/docs/src/tcp.rst index dd746fe87f..dd18522d91 100644 --- a/deps/uv/docs/src/tcp.rst +++ b/deps/uv/docs/src/tcp.rst @@ -28,9 +28,18 @@ N/A API --- -.. c:function:: int uv_tcp_init(uv_loop_t*, uv_tcp_t* handle) +.. c:function:: int uv_tcp_init(uv_loop_t* loop, uv_tcp_t* handle) - Initialize the handle. + Initialize the handle. No socket is created as of yet. + +.. c:function:: int uv_tcp_init_ex(uv_loop_t* loop, uv_tcp_t* handle, unsigned int flags) + + Initialize the handle with the specified flags. At the moment the lower 8 bits + of the `flags` parameter are used as the socket domain. A socket will be created + for the given domain. If the specified domain is ``AF_UNSPEC`` no socket is created, + just like :c:func:`uv_tcp_init`. + + .. versionadded:: 1.7.0 .. c:function:: int uv_tcp_open(uv_tcp_t* handle, uv_os_sock_t sock) diff --git a/deps/uv/docs/src/tty.rst b/deps/uv/docs/src/tty.rst index 18f34ef46d..655dca9ca2 100644 --- a/deps/uv/docs/src/tty.rst +++ b/deps/uv/docs/src/tty.rst @@ -46,7 +46,7 @@ N/A API --- -.. c:function:: int uv_tty_init(uv_loop_t*, uv_tty_t*, uv_file fd, int readable) +.. c:function:: int uv_tty_init(uv_loop_t* loop, uv_tty_t* handle, uv_file fd, int readable) Initialize a new TTY stream with the given file descriptor. Usually the file descriptor will be: @@ -70,7 +70,7 @@ API descriptor that refers to a file returns `UV_EINVAL` on UNIX. -.. c:function:: int uv_tty_set_mode(uv_tty_t*, uv_tty_mode_t mode) +.. c:function:: int uv_tty_set_mode(uv_tty_t* handle, uv_tty_mode_t mode) .. versionchanged:: 1.2.0: the mode is specified as a :c:type:`uv_tty_mode_t` value. @@ -86,7 +86,7 @@ API code ``UV_EBUSY`` if you call it when execution is inside :c:func:`uv_tty_set_mode`. -.. c:function:: int uv_tty_get_winsize(uv_tty_t*, int* width, int* height) +.. c:function:: int uv_tty_get_winsize(uv_tty_t* handle, int* width, int* height) Gets the current Window size. On success it returns 0. diff --git a/deps/uv/docs/src/udp.rst b/deps/uv/docs/src/udp.rst index ec7ce56d38..dd46603394 100644 --- a/deps/uv/docs/src/udp.rst +++ b/deps/uv/docs/src/udp.rst @@ -105,11 +105,20 @@ Public members API --- -.. c:function:: int uv_udp_init(uv_loop_t*, uv_udp_t* handle) +.. c:function:: int uv_udp_init(uv_loop_t* loop, uv_udp_t* handle) Initialize a new UDP handle. The actual socket is created lazily. Returns 0 on success. +.. c:function:: int uv_udp_init_ex(uv_loop_t* loop, uv_udp_t* handle, unsigned int flags) + + Initialize the handle with the specified flags. At the moment the lower 8 bits + of the `flags` parameter are used as the socket domain. A socket will be created + for the given domain. If the specified domain is ``AF_UNSPEC`` no socket is created, + just like :c:func:`uv_udp_init`. + + .. versionadded:: 1.7.0 + .. c:function:: int uv_udp_open(uv_udp_t* handle, uv_os_sock_t sock) Opens an existing file descriptor or Windows SOCKET as a UDP handle. diff --git a/deps/uv/docs/src/version.rst b/deps/uv/docs/src/version.rst new file mode 100644 index 0000000000..e1715b2d3c --- /dev/null +++ b/deps/uv/docs/src/version.rst @@ -0,0 +1,60 @@ + +.. _version: + +Version-checking macros and functions +===================================== + +Starting with version 1.0.0 libuv follows the `semantic versioning`_ +scheme. This means that new APIs can be introduced throughout the lifetime of +a major release. In this section you'll find all macros and functions that +will allow you to write or compile code conditionally, in order to work with +multiple libuv versions. + +.. _semantic versioning: http://semver.org + + +Macros +------ + +.. c:macro:: UV_VERSION_MAJOR + + libuv version's major number. + +.. c:macro:: UV_VERSION_MINOR + + libuv version's minor number. + +.. c:macro:: UV_VERSION_PATCH + + libuv version's patch number. + +.. c:macro:: UV_VERSION_IS_RELEASE + + Set to 1 to indicate a release version of libuv, 0 for a development + snapshot. + +.. c:macro:: UV_VERSION_SUFFIX + + libuv version suffix. Certain development releases such as Release Candidates + might have a suffix such as "rc". + +.. c:macro:: UV_VERSION_HEX + + Returns the libuv version packed into a single integer. 8 bits are used for + each component, with the patch number stored in the 8 least significant + bits. E.g. for libuv 1.2.3 this would be 0x010203. + + .. versionadded:: 1.7.0 + + +Functions +--------- + +.. c:function:: unsigned int uv_version(void) + + Returns :c:macro:`UV_VERSION_HEX`. + +.. c:function:: const char* uv_version_string(void) + + Returns the libuv version number as a string. For non-release versions the + version suffix is included. |