Lines Matching refs:buf
56 static void buf_alloc(uv_handle_t* tcp, size_t size, uv_buf_t* buf) { in buf_alloc() argument
68 *buf = ab->uv_buf_t; in buf_alloc()
72 static void buf_free(const uv_buf_t* buf) { in buf_free() argument
73 buf_t* ab = (buf_t*) buf->base - 1; in buf_free()
101 uv_buf_t buf; in pinger_write_ping() local
103 buf = uv_buf_init(PING, sizeof(PING) - 1); in pinger_write_ping()
106 if (uv_write(req, (uv_stream_t*) &pinger->tcp, &buf, 1, pinger_write_cb)) { in pinger_write_ping()
126 const uv_buf_t* buf) { in pinger_read_cb() argument
135 if (buf->base) { in pinger_read_cb()
136 buf_free(buf); in pinger_read_cb()
147 ASSERT_EQ(buf->base[i], PING[pinger->state]); in pinger_read_cb()
162 buf_free(buf); in pinger_read_cb()