test: fix double close in test-loop-handles.c
This commit is contained in:
parent
7556590707
commit
ec0c7b8958
@ -148,7 +148,7 @@ static void idle_1_cb(uv_idle_t* handle, int status) {
|
|||||||
ASSERT(idles_1_active > 0);
|
ASSERT(idles_1_active > 0);
|
||||||
|
|
||||||
/* Init idle_2 and make it active */
|
/* Init idle_2 and make it active */
|
||||||
if (!idle_2_is_active) {
|
if (!idle_2_is_active && !uv_is_closing((uv_handle_t*)&idle_2_handle)) {
|
||||||
r = uv_idle_init(uv_default_loop(), &idle_2_handle);
|
r = uv_idle_init(uv_default_loop(), &idle_2_handle);
|
||||||
ASSERT(r == 0);
|
ASSERT(r == 0);
|
||||||
r = uv_idle_start(&idle_2_handle, idle_2_cb);
|
r = uv_idle_start(&idle_2_handle, idle_2_cb);
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user