#
9b3b61f6 |
| 05-Aug-2024 |
Matheus Izvekov |
build: ubsan fixes (#4254) MSVC does not actually support ubsan. There is a long-standing ticket requesting this: https://developercommunity.visualstudio.com/t/add-support-for-ubsan/
build: ubsan fixes (#4254) MSVC does not actually support ubsan. There is a long-standing ticket requesting this: https://developercommunity.visualstudio.com/t/add-support-for-ubsan/840750 There are no known compilers that currently accept the `/fsanitize=undefined` spelling. clang-cl accepts `-fsanitize...`, same as regular clang. Also passes no-sanitizer-recover so that tests actually fail. Fix various ubsan-detected errors, including: * win: fix req-inl.h ubsan failure Don't use CONTAINING_RECORD macro from WinSDK, as it doesn't use the right trick which avoids member access on null pointer. Fixes: ``` src/win/req-inl.h:86:10: runtime error: member access within null pointer of type 'uv_req_t' (aka 'struct uv_req_s') SUMMARY: UndefinedBehaviorSanitizer: undefined-behavior D:/a/libuv/libuv/src/win/req-inl.h:86:10 ``` * test: fix ubsan failure on udp_ref3 Don't call functions through different function type. Fixes: ``` src/win/udp.c:537:5: runtime error: call to function req_cb through pointer to incorrect function type 'void (*)(struct uv_udp_send_s *, int)' test\test-ref.c:66: note: req_cb defined here SUMMARY: UndefinedBehaviorSanitizer: undefined-behavior src/win/udp.c:537:5 in ``` * win: fix process-stdio.c ubsan failure When accessing HANDLEs within the stdio buffer, use memcpy / memset in order to respect alignment. Fixes: ``` src/win/process-stdio.c:197:5: runtime error: store to misaligned address 0x0230ee72d107 for type 'HANDLE' (aka 'void *'), which requires 8 byte alignment 0x0230ee72d107: note: pointer points here 00 00 cd cd cd cd cd cd cd cd cd cd cd cd cd cd cd cd cd cd cd cd cd cd cd cd cd cd fd fd fd fd ^ SUMMARY: UndefinedBehaviorSanitizer: undefined-behavior src/win/process-stdio.c:197:5 in ``` * win: fix getaddrinfo.c ubsan failure Reworks buffer alignment handling to respect requirements. Fixes: ``` src/win/getaddrinfo.c:157:23: runtime error: member access within misaligned address 0x0290e4c6a17c for type 'struct addrinfo', which requires 8 byte alignment 0x0290e4c6a17c: note: pointer points here 00 00 00 00 cd cd cd cd cd cd cd cd cd cd cd cd cd cd cd cd cd cd cd cd cd cd cd cd cd cd cd cd ^ SUMMARY: UndefinedBehaviorSanitizer: undefined-behavior src/win/getaddrinfo.c:157:23 in ``` * win: fix pipe.c ubsan failure Changes "random" representation from pointer to number. Fixes: ``` src/win/pipe.c:234:11: runtime error: applying non-zero offset to non-null pointer 0xffffffffffffffff produced null pointer SUMMARY: UndefinedBehaviorSanitizer: undefined-behavior src/win/pipe.c:234:11 in ``` * unix: fix stream.c ubsan failure Avoids performing pointer arithmetic on null pointer. Fixes: ``` src/unix/stream.c:701:15: runtime error: applying zero offset to null pointer SUMMARY: UndefinedBehaviorSanitizer: undefined-behavior /Users/runner/work/libuv/libuv/src/unix/stream.c:701:15 in ```
show more ...
|
#
7c491bde |
| 11-Jul-2024 |
Viacheslav Muravyev |
unix,win: remove unused req parameter from macros (#4435) Remove the unused `req` parameter from the uv__req_register and uv__req_unregister macros.
|
#
ee970e38 |
| 11-Jul-2022 |
Jameson Nash |
win,shutdown: improve how shutdown is dispatched (#3649) Split this off from endgame, so that it can be handled separately and earlier, rather than trying to detect inside endgame which
win,shutdown: improve how shutdown is dispatched (#3649) Split this off from endgame, so that it can be handled separately and earlier, rather than trying to detect inside endgame which case we are in. There appear to be some race conditions on the `handle` field still however, which this does not yet attempt to address.
show more ...
|
#
1fe609ea |
| 06-Apr-2022 |
Ben Noordhuis |
unix,win: fix UV_RUN_ONCE + uv_idle_stop loop hang (#3590) Wrong accounting of idle handles in uv_run() made it sleep when there was nothing left to do. Do a non-blocking poll for I/O in
unix,win: fix UV_RUN_ONCE + uv_idle_stop loop hang (#3590) Wrong accounting of idle handles in uv_run() made it sleep when there was nothing left to do. Do a non-blocking poll for I/O instead.
show more ...
|
#
d54c92e3 |
| 15-Feb-2022 |
Jameson Nash |
win: fix style nits [NFC] (#3474) Internal functions usually have a uv__ prefix.
|
Revision tags: v1.41.0, v1.40.0, v1.39.0, v1.38.1, v1.38.0, v1.37.0, v1.36.0, v1.35.0, v1.34.2, v1.34.1, v1.34.0, v1.33.1, v1.33.0, v1.32.0, v1.31.0, v1.30.1, v1.30.0, v1.29.1, v1.29.0, v1.28.0, v1.27.0, v1.26.0, v1.25.0, v1.24.1, v1.24.0, v1.23.2, v1.23.1, v1.23.0, v1.22.0, v1.21.0, v1.20.3, v1.20.2, v1.20.1, v1.20.0, v1.19.2, v1.19.1, v1.19.0, v1.18.0, v1.17.0, v1.16.1, v1.16.0, v1.15.0, v1.14.1, v1.14.0, v1.13.1, v1.13.0, v1.12.0, v1.11.0, v1.10.2, v1.10.1, v1.10.0 |
|
#
87df1448 |
| 14-Oct-2016 |
Ben Noordhuis |
unix,windows: refactor request init logic Fixes a TODO in src/threadpool.c. Updates the Windows code to drop the unused `loop` parameter in calls to uv_req_init(). PR-URL: http
unix,windows: refactor request init logic Fixes a TODO in src/threadpool.c. Updates the Windows code to drop the unused `loop` parameter in calls to uv_req_init(). PR-URL: https://github.com/libuv/libuv/pull/1091 Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.com> Reviewed-By: Saúl Ibarra Corretgé <saghul@gmail.com>
show more ...
|
Revision tags: v0.10.37, v1.9.1, v1.9.0, v1.8.0, v1.7.5, v1.7.4, v1.7.3, v1.7.2, v1.7.1, v1.7.0, v1.6.1, v1.6.0, v1.5.0 |
|
#
c7ebe68f |
| 03-Mar-2015 |
Alexis Campailla |
win: fix pipe blocking writes In the code path for pipe blocking writes, WriteFile is already posting a completion packet to the I/O completion port. POST_COMPLETION_FOR_REQ was caus
win: fix pipe blocking writes In the code path for pipe blocking writes, WriteFile is already posting a completion packet to the I/O completion port. POST_COMPLETION_FOR_REQ was causing the same request to get returned twice by GetCompletionStatusEx. Also on the same code path, we were waiting on the wrong event. PR-URL: https://github.com/libuv/libuv/pull/238 Reviewed-By: Bert Belder <bertbelder@gmail.com>
show more ...
|
#
073323ba |
| 03-Mar-2015 |
TomCrypto |
win: name all anonymous structs and unions All the public structs and unions in the private fields in uv-win.h have been named and all code accessing them updated, to comply to the C89
win: name all anonymous structs and unions All the public structs and unions in the private fields in uv-win.h have been named and all code accessing them updated, to comply to the C89 spec (which were previously causing warnings with the -pedantic flag). PR-URL: https://github.com/libuv/libuv/pull/239 Reviewed-By: Andrius Bentkus <andrius.bentkus@gmail.com> Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By: Saúl Ibarra Corretgé <saghul@gmail.com>
show more ...
|
Revision tags: v0.10.36, v1.4.2, v0.10.35, v1.4.1, v0.10.34, v1.4.0, v1.3.0, v0.10.33, v1.2.1, v1.2.0, v0.10.32, v1.1.0, v0.10.31 |
|
#
e58dc269 |
| 11-Dec-2014 |
Saúl Ibarra Corretgé |
unix, windows: fix UV_RUN_ONCE mode if progress was made If pending I/O callbacks were ran before polling, do a zero timeout poll. PR-URL: https://github.com/libuv/libuv/pull/58
unix, windows: fix UV_RUN_ONCE mode if progress was made If pending I/O callbacks were ran before polling, do a zero timeout poll. PR-URL: https://github.com/libuv/libuv/pull/58 Reviewed-By: Bert Belder <bertbelder@gmail.com> Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
show more ...
|
Revision tags: v1.0.2, v0.10.30, v1.0.1, v1.0.0, v0.10.29, v1.0.0-rc2, v1.0.0-rc1, v0.11.29, v0.11.28, v0.11.27, v0.10.28, v0.11.26 |
|
#
8d11aacb |
| 17-Jun-2014 |
Saúl Ibarra Corretgé |
unix, windows: use the same threadpool implementation |
#
70c42563 |
| 11-May-2014 |
Rasmus Christian Pedersen |
unix, windows: getnameinfo implementation Closes #852 |
Revision tags: v0.10.27, v0.11.25, v0.11.24, v0.11.23, v0.10.26, v0.11.22, v0.11.21, v0.11.20, v0.10.25, v0.11.19, v0.10.24, v0.11.18, v0.10.23, v0.10.22, v0.11.17, v0.10.21, v0.11.16, v0.10.20, v0.11.15, v0.10.19, v0.11.14, v0.10.18, v0.10.17, v0.10.16, v0.11.13, v0.11.12, v0.11.11, v0.11.10, v0.10.15, v0.11.9, v0.10.14, v0.11.8, v0.11.7, v0.10.13, v0.11.6, v0.10.12, v0.11.5, v0.10.11, v0.10.10, v0.11.4, v0.10.9, v0.10.8, v0.11.3, v0.10.7, v0.10.6, v0.11.2, v0.10.5, v0.10.4, v0.11.1, node-v0.11.0, v0.10.2, node-v0.7.3, node-v0.7.7, node-v0.7.5, node-v0.5.3, node-v0.10.1, node-v0.10.0, node-v0.9.12, node-v0.9.11, node-v0.8.21, node-v0.8.19, node-v0.9.10, node-v0.9.7, node-v0.9.6, node-v0.9.4, node-v0.8.17, node-v0.8.15, node-v0.9.3, node-v0.8.12, node-v0.8.10, node-v0.9.2, node-v0.8.9, node-v0.9.1, node-v0.8.8 |
|
#
c4dbb60c |
| 15-Aug-2012 |
Bert Belder |
windows: basic signal handling support with uv_signal_t This still needs tests. |
#
aa69f34d |
| 13-Aug-2012 |
Bert Belder |
windows: report spawn errors to the exit callback Formerly spawn errors would be reported as a message printed to the process' stderr, to match unix behaviour. Unix has now been fixed to
windows: report spawn errors to the exit callback Formerly spawn errors would be reported as a message printed to the process' stderr, to match unix behaviour. Unix has now been fixed to be more sensible, so this hack can now be removed. This also fixes a race condition that could occur when the user closes a process handle before the exit callback has been made.
show more ...
|
Revision tags: node-v0.8.7 |
|
#
837edf4c |
| 09-Aug-2012 |
Ben Noordhuis |
unix, windows: remove handle init counters Remove the handle init counters, no one uses them. |
Revision tags: node-v0.8.6, node-v0.8.5, node-v0.6.21, node-v0.8.3, node-v0.9.0, node-v0.8.2, node-v0.8.1, node-v0.8.0, node-v0.7.12, node-v0.7.11, node-v0.7.10, node-v0.6.19 |
|
#
829eaf3e |
| 04-Jun-2012 |
Bert Belder |
windows: cast OVERLAPPED.Internal to NTSTATUS to avoid warnings |
#
754a695d |
| 04-Jun-2012 |
Bert Belder |
windows: move request macros to req-inl.h |
#
1974541b |
| 04-Jun-2012 |
Bert Belder |
windows: guard against including req-inl.h more than once |
#
d4026041 |
| 02-Jun-2012 |
Bert Belder |
windows: inline a couple of inline request functions |