Lines Matching defs:handle

41 static void once_close_cb(uv_handle_t* handle) {
44 ASSERT_NOT_NULL(handle);
45 ASSERT_OK(uv_is_active(handle));
51 static void once_cb(uv_timer_t* handle) {
54 ASSERT_NOT_NULL(handle);
55 ASSERT_OK(uv_is_active((uv_handle_t*) handle));
59 uv_close((uv_handle_t*)handle, once_close_cb);
65 static void twice_close_cb(uv_handle_t* handle) {
68 ASSERT_NOT_NULL(handle);
69 ASSERT_OK(uv_is_active(handle));
74 static void twice_cb(uv_timer_t* handle) {
77 ASSERT_NOT_NULL(handle);
78 ASSERT_OK(uv_is_active((uv_handle_t*) handle));
82 uv_close((uv_handle_t*)handle, twice_close_cb);
87 static void repeat_close_cb(uv_handle_t* handle) {
90 ASSERT_NOT_NULL(handle);
96 static void repeat_cb(uv_timer_t* handle) {
99 ASSERT_NOT_NULL(handle);
100 ASSERT_EQ(1, uv_is_active((uv_handle_t*) handle));
105 uv_close((uv_handle_t*)handle, repeat_close_cb);
110 static void never_cb(uv_timer_t* handle) {
185 uv_timer_t handle;
187 ASSERT_OK(uv_timer_init(uv_default_loop(), &handle));
188 ASSERT_OK(uv_timer_get_repeat(&handle));
189 ASSERT_UINT64_LE(0, uv_timer_get_due_in(&handle));
190 ASSERT_OK(uv_is_active((uv_handle_t*) &handle));
197 static void order_cb_a(uv_timer_t *handle) {
198 ASSERT_EQ(order_cb_called++, *(int*)handle->data);
202 static void order_cb_b(uv_timer_t *handle) {
203 ASSERT_EQ(order_cb_called++, *(int*)handle->data);
246 static void zero_timeout_cb(uv_timer_t* handle) {
247 ASSERT_OK(uv_timer_start(handle, zero_timeout_cb, 0, 0));
248 uv_stop(handle->loop);
271 static void tiny_timer_cb(uv_timer_t* handle) {
272 ASSERT_PTR_EQ(handle, &tiny_timer);
298 static void huge_repeat_cb(uv_timer_t* handle) {
302 ASSERT_PTR_EQ(handle, &huge_timer1);
304 ASSERT_PTR_EQ(handle, &tiny_timer);
327 static void timer_run_once_timer_cb(uv_timer_t* handle) {
353 uv_timer_t handle;
355 ASSERT_OK(uv_timer_init(uv_default_loop(), &handle));
356 uv_close((uv_handle_t *)&handle, NULL);
358 ASSERT_EQ(UV_EINVAL, uv_timer_start(&handle, never_cb, 100, 100));
366 uv_timer_t handle;
368 ASSERT_OK(uv_timer_init(uv_default_loop(), &handle));
369 ASSERT_EQ(UV_EINVAL, uv_timer_start(&handle, NULL, 100, 100));
379 static void timer_early_check_cb(uv_timer_t* handle) {
405 static void timer_check_double_call(uv_timer_t* handle) {