test: use uv_loop_close and assert its result
uv_loop_delete is considered deprecated. PR-URL: https://github.com/libuv/libuv/pull/696 Reviewed-By: Saúl Ibarra Corretgé <saghul@gmail.com>
This commit is contained in:
parent
51c1a28d7e
commit
b6650dff56
@ -108,10 +108,10 @@ typedef enum {
|
||||
/* This macro cleans up the main loop. This is used to avoid valgrind
|
||||
* warnings about memory being "leaked" by the main event loop.
|
||||
*/
|
||||
#define MAKE_VALGRIND_HAPPY() \
|
||||
do { \
|
||||
close_loop(uv_default_loop()); \
|
||||
uv_loop_delete(uv_default_loop()); \
|
||||
#define MAKE_VALGRIND_HAPPY() \
|
||||
do { \
|
||||
close_loop(uv_default_loop()); \
|
||||
ASSERT(0 == uv_loop_close(uv_default_loop())); \
|
||||
} while (0)
|
||||
|
||||
/* Just sugar for wrapping the main() for a task or helper. */
|
||||
|
||||
Loading…
Reference in New Issue
Block a user