diff options
author | Bartosz Sosnowski <bartosz@janeasystems.com> | 2020-04-29 13:14:57 +0200 |
---|---|---|
committer | Bartosz Sosnowski <bartosz@janeasystems.com> | 2020-04-29 13:14:57 +0200 |
commit | 457285827cfcc6bbe33abe9bd211e7cee332b3c5 (patch) | |
tree | 501bf425911a0c18aba20b7fb3799769f0749f6e /docs/src | |
parent | 2bbf7d5c8cd070cc8541698fe72136328bc18eae (diff) | |
download | libuv-457285827cfcc6bbe33abe9bd211e7cee332b3c5.tar.gz libuv-457285827cfcc6bbe33abe9bd211e7cee332b3c5.zip |
fs: report original error
Exposes the original system error of the filesystem syscalls. Adds a new
uv_fs_get_system_error which returns orignal errno on Linux or
GetLastError on Windows.
Ref: https://github.com/libuv/libuv/issues/2348
PR-URL: https://github.com/libuv/libuv/pull/2810
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.com>
Diffstat (limited to 'docs/src')
-rw-r--r-- | docs/src/fs.rst | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/docs/src/fs.rst b/docs/src/fs.rst index a475a460..73666f3c 100644 --- a/docs/src/fs.rst +++ b/docs/src/fs.rst @@ -492,6 +492,13 @@ API .. versionadded:: 1.19.0 +.. c:function:: int uv_fs_get_system_error(const uv_fs_t* req) + + Returns the platform specific error code - `GetLastError()` value on Windows + and `-(req->result)` on other platforms. + + .. versionadded:: 1.38.0 + .. c:function:: void* uv_fs_get_ptr(const uv_fs_t* req) Returns `req->ptr`. |