Home
last modified time | relevance | path

Searched refs:tocopy (Results 1 – 10 of 10) sorted by relevance

/netbsd/src/lib/libc/stdio/
Dopen_memstream.c97 size_t tocopy; in memstream_write() local
105 tocopy = ms->len - ms->offset; in memstream_write()
106 if (len < tocopy) in memstream_write()
107 tocopy = len; in memstream_write()
108 memcpy(*ms->bufp + ms->offset, buf, tocopy); in memstream_write()
109 ms->offset += tocopy; in memstream_write()
112 fprintf(stderr, "MS: write(%p, %zu) = %zu\n", ms, len, tocopy); in memstream_write()
114 return (ssize_t)tocopy; in memstream_write()
/netbsd/src/sys/fs/ntfs/
Dntfs_subr.c1262 size_t tocopy; in ntfs_writentvattr_plain() local
1306 tocopy = MIN(left, ntfs_cntob(1) - off); in ntfs_writentvattr_plain()
1307 cl = ntfs_btocl(tocopy + off); in ntfs_writentvattr_plain()
1308 KASSERT(cl == 1 && tocopy <= ntfs_cntob(1)); in ntfs_writentvattr_plain()
1312 (long long) off, (long long) tocopy, in ntfs_writentvattr_plain()
1314 if ((off == 0) && (tocopy == ntfs_cntob(cl))) { in ntfs_writentvattr_plain()
1326 uiomove((char *)bp->b_data + off, tocopy, uio); in ntfs_writentvattr_plain()
1328 memcpy((char *)bp->b_data + off, data, tocopy); in ntfs_writentvattr_plain()
1330 data = (char *)data + tocopy; in ntfs_writentvattr_plain()
1331 *initp += tocopy; in ntfs_writentvattr_plain()
[all …]
/netbsd/src/sys/kern/
Dsubr_iostat.c405 size_t tocopy, left; in sysctl_hw_iostats() local
417 tocopy = offsetof(struct io_sysctl, busy); in sysctl_hw_iostats()
419 tocopy = name[0]; in sysctl_hw_iostats()
422 *oldlenp = iostat_count * tocopy; in sysctl_hw_iostats()
433 if (left < tocopy) in sysctl_hw_iostats()
469 error = copyout(&sdrive, where, uimin(tocopy, sizeof(sdrive))); in sysctl_hw_iostats()
472 where += tocopy; in sysctl_hw_iostats()
473 *oldlenp += tocopy; in sysctl_hw_iostats()
474 left -= tocopy; in sysctl_hw_iostats()
/netbsd/src/sys/arch/hpc/stand/hpcboot/
Dload.cpp221 vsize_t tocopy = (remsz < _tpsz) ? remsz : _tpsz; in _load_memory() local
222 memcpy((void *)v, data, tocopy); in _load_memory()
225 _pvec_prev->sz = tocopy; in _load_memory()
231 data = (char *)data + tocopy; in _load_memory()
232 dst += tocopy; in _load_memory()
233 remsz -= tocopy; in _load_memory()
/netbsd/src/sys/opencrypto/
Ddeflate.c87 u_int32_t count, result, tocopy; in deflate_global() local
167 tocopy = MIN(count, buf[j].size); in deflate_global()
169 KASSERT(tocopy || j == (i - 1)); in deflate_global()
170 memcpy(output, buf[j].out, tocopy); in deflate_global()
171 output += tocopy; in deflate_global()
173 count -= tocopy; in deflate_global()
/netbsd/src/external/gpl3/binutils/dist/binutils/
Dar.c1088 bfd_size_type tocopy = size - ncopied; in print_contents() local
1090 if (tocopy > BUFSIZE) in print_contents()
1091 tocopy = BUFSIZE; in print_contents()
1093 nread = bfd_read (cbuf, tocopy, abfd); in print_contents()
1094 if (nread != tocopy) in print_contents()
1104 ncopied += tocopy; in print_contents()
1195 bfd_size_type nread, tocopy; in extract_file() local
1197 tocopy = size - ncopied; in extract_file()
1198 if (tocopy > BUFSIZE) in extract_file()
1199 tocopy = BUFSIZE; in extract_file()
[all …]
Dobjcopy.c1946 bfd_size_type tocopy; in copy_unknown_object() local
1978 tocopy = BUFSIZE; in copy_unknown_object()
1980 tocopy = size; in copy_unknown_object()
1982 if (bfd_read (cbuf, tocopy, ibfd) != tocopy) in copy_unknown_object()
1989 if (bfd_write (cbuf, tocopy, obfd) != tocopy) in copy_unknown_object()
1996 size -= tocopy; in copy_unknown_object()
/netbsd/src/sys/netinet/
Daccf_http.c379 int tocopy; in soishttpconnected() local
381 tocopy = (NCHRS - ccleft) - copied; in soishttpconnected()
382 src = mtod(m, char *) + (m->m_len - tocopy); in soishttpconnected()
384 while (tocopy--) { in soishttpconnected()
/netbsd/src/external/bsd/libarchive/dist/libarchive/
Darchive_read.c1329 size_t tocopy; in __archive_read_filter_ahead() local
1475 tocopy = (filter->buffer + filter->buffer_size) in __archive_read_filter_ahead()
1478 if (tocopy + filter->avail > min) in __archive_read_filter_ahead()
1479 tocopy = min - filter->avail; in __archive_read_filter_ahead()
1481 if (tocopy > filter->client_avail) in __archive_read_filter_ahead()
1482 tocopy = filter->client_avail; in __archive_read_filter_ahead()
1485 filter->client_next, tocopy); in __archive_read_filter_ahead()
1487 filter->client_next += tocopy; in __archive_read_filter_ahead()
1488 filter->client_avail -= tocopy; in __archive_read_filter_ahead()
1490 filter->avail += tocopy; in __archive_read_filter_ahead()
/netbsd/src/external/gpl3/binutils/dist/
DChangeLog.git162001 "tocopy" in this code was an int, which when the size to be copied was
162002 larger than MAXINT could result in tocopy being negative. A negative
162007 * objcopy.c (copy_unknown_object): Correct calculation of "tocopy".