Home
last modified time | relevance | path

Searched refs:bufs (Results 1 – 25 of 29) sorted by relevance

12

/libuv/src/win/
H A Dstream.c116 const uv_buf_t bufs[], in uv_write() argument
129 err = uv__tcp_write(loop, req, (uv_tcp_t*) handle, bufs, nbufs, cb); in uv_write()
133 loop, req, (uv_pipe_t*) handle, bufs, nbufs, NULL, cb); in uv_write()
148 const uv_buf_t bufs[], in uv_write2() argument
156 return uv_write(req, handle, bufs, nbufs, cb); in uv_write2()
166 loop, req, (uv_pipe_t*) handle, bufs, nbufs, send_handle, cb); in uv_write2()
172 const uv_buf_t bufs[], in uv_try_write() argument
181 return uv__tcp_try_write((uv_tcp_t*) stream, bufs, nbufs); in uv_try_write()
183 return uv__tty_try_write((uv_tty_t*) stream, bufs, nbufs); in uv_try_write()
194 const uv_buf_t bufs[], in uv_try_write2() argument
[all …]
H A Dinternal.h80 const uv_buf_t bufs[], unsigned int nbufs, uv_write_cb cb);
81 int uv__tcp_try_write(uv_tcp_t* handle, const uv_buf_t bufs[],
132 const uv_buf_t bufs[],
162 const uv_buf_t bufs[], unsigned int nbufs, uv_write_cb cb);
163 int uv__tty_try_write(uv_tty_t* handle, const uv_buf_t bufs[],
H A Dfs.c3008 uv__free(req->fs.info.bufs); in uv_fs_req_cleanup()
3013 req->fs.info.bufs = NULL; in uv_fs_req_cleanup()
3047 const uv_buf_t bufs[], in uv_fs_read() argument
3053 if (bufs == NULL || nbufs == 0) { in uv_fs_read()
3063 req->fs.info.bufs = uv__malloc(nbufs * sizeof(*bufs)); in uv_fs_read()
3065 if (req->fs.info.bufs == NULL) { in uv_fs_read()
3070 memcpy(req->fs.info.bufs, bufs, nbufs * sizeof(*bufs)); in uv_fs_read()
3086 if (bufs == NULL || nbufs == 0) { in uv_fs_write()
3096 req->fs.info.bufs = uv__malloc(nbufs * sizeof(*bufs)); in uv_fs_write()
3098 if (req->fs.info.bufs == NULL) { in uv_fs_write()
[all …]
H A Dpipe.c1538 data_length += bufs[i].len; in uv__build_coalesced_write_req()
1565 bufs[i].base, in uv__build_coalesced_write_req()
1616 write_buf = bufs[0]; in uv__pipe_write_data()
1754 uv_buf_t* bufs; in uv__pipe_write_ipc() local
1796 bufs = stack_bufs; in uv__pipe_write_ipc()
1799 bufs = uv__calloc(buf_count, sizeof(uv_buf_t)); in uv__pipe_write_ipc()
1800 if (bufs == NULL) in uv__pipe_write_ipc()
1832 bufs[buf_index++] = data_bufs[i]; in uv__pipe_write_ipc()
1840 if (bufs != stack_bufs) { in uv__pipe_write_ipc()
1841 uv__free(bufs); in uv__pipe_write_ipc()
[all …]
H A Dudp.c356 const uv_buf_t bufs[], in uv__send() argument
370 (WSABUF*)bufs, in uv__send()
389 req->u.io.queued_bytes = uv__count_bufs(bufs, nbufs); in uv__send()
1065 const uv_buf_t bufs[], in uv__udp_send() argument
1086 err = uv__send(req, handle, bufs, nbufs, addr, addrlen, send_cb); in uv__udp_send()
1095 const uv_buf_t bufs[], in uv__udp_try_send() argument
1130 (WSABUF*)bufs, in uv__udp_try_send()
H A Dtty.c1664 const uv_buf_t bufs[], argument
1699 uv_buf_t buf = bufs[i];
2175 const uv_buf_t bufs[], argument
2190 if (!uv__tty_write_bufs(handle, bufs, nbufs, &error)) {
2203 const uv_buf_t bufs[], argument
2210 if (uv__tty_write_bufs(handle, bufs, nbufs, &error))
2213 return uv__count_bufs(bufs, nbufs);
H A Dtcp.c894 const uv_buf_t bufs[], in uv__tcp_write() argument
916 (WSABUF*) bufs, in uv__tcp_write()
932 req->u.io.queued_bytes = uv__count_bufs(bufs, nbufs); in uv__tcp_write()
959 const uv_buf_t bufs[], in uv__tcp_try_write() argument
968 (WSABUF*) bufs, in uv__tcp_try_write()
/libuv/test/
H A Dbenchmark-udp-pummel.c51 static uv_buf_t bufs[5]; variable
101 bufs, in send_cb()
102 ARRAY_SIZE(bufs), in send_cb()
182 bufs[0] = uv_buf_init(&EXPECTED[0], 10); in pummel()
183 bufs[1] = uv_buf_init(&EXPECTED[10], 10); in pummel()
184 bufs[2] = uv_buf_init(&EXPECTED[20], 10); in pummel()
185 bufs[3] = uv_buf_init(&EXPECTED[30], 10); in pummel()
186 bufs[4] = uv_buf_init(&EXPECTED[40], 5); in pummel()
196 bufs, in pummel()
197 ARRAY_SIZE(bufs), in pummel()
H A Dtest-close-fd.c54 uv_buf_t bufs[1]; in TEST_IMPL() local
56 bufs[0] = uv_buf_init("", 1); in TEST_IMPL()
64 ASSERT_EQ(1, uv_fs_write(NULL, &req, fd[1], bufs, 1, -1, NULL)); in TEST_IMPL()
H A Dtest-pipe-set-non-blocking.c32 uv_buf_t bufs[1]; in thread_main() local
37 bufs[0] = uv_buf_init(buf, sizeof(buf)); in thread_main()
44 uv_errno = uv_fs_read(NULL, &req, ctx->fd, bufs, 1, -1, NULL); in thread_main()
H A Dtest-tty.c223 uv_buf_t bufs[1]; in TEST_IMPL() local
250 bufs[0].len = 0; in TEST_IMPL()
251 bufs[0].base = &dummy[0]; in TEST_IMPL()
253 r = uv_try_write((uv_stream_t*) &tty_out, bufs, 1); in TEST_IMPL()
269 uv_buf_t bufs[1]; in TEST_IMPL() local
297 bufs[0] = uv_buf_init(dummy, sizeof(dummy)); in TEST_IMPL()
299 r = uv_try_write((uv_stream_t*) &tty_out, bufs, 1); in TEST_IMPL()
H A Dtest-ipc-heavy-traffic-deadlock-bug.c64 uv_buf_t bufs[BUFFERS_PER_WRITE]; in do_write() local
73 bufs[i] = uv_buf_init(write_info->buffers[i], BUFFER_SIZE); in do_write()
77 &write_info->write_req, handle, bufs, BUFFERS_PER_WRITE, write_cb); in do_write()
H A Dtest-ping-pong.c95 uv_buf_t bufs[sizeof PING - 1]; in pinger_write_ping() local
103 bufs[0] = uv_buf_init(PING, sizeof PING - 1); in pinger_write_ping()
108 bufs[i] = uv_buf_init(&PING[i], 1); in pinger_write_ping()
115 ASSERT_OK(uv_write(req, stream, bufs, nbufs, pinger_after_write)); in pinger_write_ping()
H A Dtest-fs.c3231 uv_buf_t bufs[4]; in fs_read_bufs() local
3246 bufs[0] = uv_buf_init(scratch + 0, 256); in fs_read_bufs()
3254 bufs + 0, in fs_read_bufs()
3264 bufs + 2, in fs_read_bufs()
3271 ASSERT_OK(memcmp(bufs[1].base + 0, bufs[2].base, 128)); in fs_read_bufs()
3272 ASSERT_OK(memcmp(bufs[1].base + 128, bufs[3].base, 190 - 128)); in fs_read_bufs()
3787 size -= bufs[offset].len; in uv_test_fs_buf_offset()
3791 bufs[offset].base += size; in uv_test_fs_buf_offset()
3792 bufs[offset].len -= size; in uv_test_fs_buf_offset()
3913 ASSERT_NULL(write_req.fs.info.bufs); in TEST_IMPL()
[all …]
/libuv/src/unix/
H A Dfs.c526 bufs = (const struct iovec*) req->bufs; in uv__fs_read()
536 r = read(fd, bufs->iov_base, bufs->iov_len); in uv__fs_read()
541 r = pread(fd, bufs->iov_base, bufs->iov_len, off); in uv__fs_read()
1221 bufs = (const struct iovec*) req->bufs; in uv__fs_write()
1227 r = write(fd, bufs->iov_base, bufs->iov_len); in uv__fs_write()
1232 r = pwrite(fd, bufs->iov_base, bufs->iov_len, off); in uv__fs_write()
1658 bufs = req->bufs; in uv__fs_write_all()
2053 req->bufs = uv__malloc(nbufs * sizeof(*bufs)); in uv_fs_read()
2058 memcpy(req->bufs, bufs, nbufs * sizeof(*bufs)); in uv_fs_read()
2238 req->bufs = uv__malloc(nbufs * sizeof(*bufs)); in uv_fs_write()
[all …]
H A Dstream.c673 assert(req->bufs != NULL); in uv__write_req_size()
728 uv__free(req->bufs); in uv__write_req_finish()
729 req->bufs = NULL; in uv__write_req_finish()
767 iov = (struct iovec*) bufs; in uv__try_write()
918 if (req->bufs != NULL) { in uv__write_callbacks()
921 uv__free(req->bufs); in uv__write_callbacks()
922 req->bufs = NULL; in uv__write_callbacks()
1362 req->bufs = req->bufsml; in uv_write2()
1364 req->bufs = uv__malloc(nbufs * sizeof(bufs[0])); in uv_write2()
1366 if (req->bufs == NULL) in uv_write2()
[all …]
H A Dudp.c108 if (req->bufs != req->bufsml) in uv__udp_run_completed()
109 uv__free(req->bufs); in uv__udp_run_completed()
110 req->bufs = NULL; in uv__udp_run_completed()
308 h.msg_iov = (struct iovec*) req->bufs; in uv__udp_sendmsg_one()
408 req->status = req->bufs[0].len; in uv__udp_sendmsg_many()
723 const uv_buf_t bufs[], in uv__udp_send() argument
755 req->bufs = req->bufsml; in uv__udp_send()
757 req->bufs = uv__malloc(nbufs * sizeof(bufs[0])); in uv__udp_send()
759 if (req->bufs == NULL) { in uv__udp_send()
764 memcpy(req->bufs, bufs, nbufs * sizeof(bufs[0])); in uv__udp_send()
[all …]
/libuv/include/uv/
H A Dunix.h262 uv_buf_t* bufs; \
276 uv_buf_t* bufs; \
367 uv_buf_t* bufs; \
H A Dwin.h636 uv_buf_t* bufs; \
/libuv/src/
H A Duv-common.h182 const uv_buf_t bufs[],
189 const uv_buf_t bufs[],
217 size_t uv__count_bufs(const uv_buf_t bufs[], unsigned int nbufs);
H A Duv-common.c489 const uv_buf_t bufs[], in uv_udp_send() argument
499 return uv__udp_send(req, handle, bufs, nbufs, addr, addrlen, send_cb); in uv_udp_send()
504 const uv_buf_t bufs[], in uv_udp_try_send() argument
513 return uv__udp_try_send(handle, bufs, nbufs, addr, addrlen); in uv_udp_try_send()
625 size_t uv__count_bufs(const uv_buf_t bufs[], unsigned int nbufs) { in uv__count_bufs() argument
631 bytes += (size_t) bufs[i].len; in uv__count_bufs()
/libuv/docs/src/
H A Dstream.rst159 .. c:function:: int uv_write(uv_write_t* req, uv_stream_t* handle, const uv_buf_t bufs[], unsigned …
190 .. c:function:: int uv_write2(uv_write_t* req, uv_stream_t* handle, const uv_buf_t bufs[], unsigned…
200 .. c:function:: int uv_try_write(uv_stream_t* handle, const uv_buf_t bufs[], unsigned int nbufs)
211 .. c:function:: int uv_try_write2(uv_stream_t* handle, const uv_buf_t bufs[], unsigned int nbufs, u…
H A Dudp.rst375 .. c:function:: int uv_udp_send(uv_udp_send_t* req, uv_udp_t* handle, const uv_buf_t bufs[], unsign…
396 :param bufs: List of buffers to send.
398 :param nbufs: Number of buffers in `bufs`.
412 .. c:function:: int uv_udp_try_send(uv_udp_t* handle, const uv_buf_t bufs[], unsigned int nbufs, co…
/libuv/include/
H A Duv.h553 const uv_buf_t bufs[],
558 const uv_buf_t bufs[],
563 const uv_buf_t bufs[],
566 const uv_buf_t bufs[],
771 const uv_buf_t bufs[],
776 const uv_buf_t bufs[],
1463 const uv_buf_t bufs[],
1474 const uv_buf_t bufs[],
/libuv/docs/src/guide/
H A Dfilesystem.rst129 …int uv_fs_read(uv_loop_t* loop, uv_fs_t* req, uv_file file, const uv_buf_t bufs[], unsigned int nb…
131 …int uv_fs_write(uv_loop_t* loop, uv_fs_t* req, uv_file file, const uv_buf_t bufs[], unsigned int n…
182 const uv_buf_t bufs[], unsigned int nbufs, uv_write_cb cb);

Completed in 100 milliseconds

12