| /netbsd-src/lib/libc/stdio/ |
| H A D | open_memstream.c | 97 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/ |
| H A D | ntfs_subr.c | 1262 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/ |
| H A D | subr_iostat.c | 405 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/ |
| H A D | load.cpp | 221 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/external/bsd/unbound/dist/sldns/ |
| H A D | sbuffer.c | 153 size_t tocopy = sldns_buffer_limit(from); in sldns_buffer_copy() local 155 if(tocopy > sldns_buffer_capacity(result)) in sldns_buffer_copy() 156 tocopy = sldns_buffer_capacity(result); in sldns_buffer_copy() 158 sldns_buffer_write(result, sldns_buffer_begin(from), tocopy); in sldns_buffer_copy()
|
| H A D | str2wire.c | 201 uint8_t* tocopy; in rrinternal_get_owner() local 204 tocopy = origin; in rrinternal_get_owner() 207 tocopy = prev; in rrinternal_get_owner() 211 tocopy = (uint8_t*)"\0"; in rrinternal_get_owner() 216 memmove(rr, tocopy, *dname_len); in rrinternal_get_owner() 220 uint8_t* tocopy; in rrinternal_get_owner() local 223 tocopy = prev; in rrinternal_get_owner() 226 tocopy = origin; in rrinternal_get_owner() 229 tocopy = (uint8_t*)"\0"; in rrinternal_get_owner() 234 memmove(rr, tocopy, *dname_len); in rrinternal_get_owner() [all …]
|
| /netbsd-src/sys/opencrypto/ |
| H A D | deflate.c | 87 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.old/dist/binutils/ |
| H A D | ar.c | 1100 bfd_size_type tocopy = size - ncopied; in print_contents() local 1102 if (tocopy > BUFSIZE) in print_contents() 1103 tocopy = BUFSIZE; in print_contents() 1105 nread = bfd_bread (cbuf, tocopy, abfd); in print_contents() 1106 if (nread != tocopy) in print_contents() 1116 ncopied += tocopy; in print_contents() 1206 bfd_size_type nread, tocopy; in extract_file() local 1208 tocopy = size - ncopied; in extract_file() 1209 if (tocopy > BUFSIZE) in extract_file() 1210 tocopy = BUFSIZE; in extract_file() [all …]
|
| H A D | objcopy.c | 1909 bfd_size_type tocopy; in copy_unknown_object() local 1941 tocopy = BUFSIZE; in copy_unknown_object() 1943 tocopy = size; in copy_unknown_object() 1945 if (bfd_bread (cbuf, tocopy, ibfd) != tocopy) in copy_unknown_object() 1952 if (bfd_bwrite (cbuf, tocopy, obfd) != tocopy) in copy_unknown_object() 1959 size -= tocopy; in copy_unknown_object()
|
| /netbsd-src/external/gpl3/binutils/dist/binutils/ |
| H A D | ar.c | 1088 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 …]
|
| H A D | objcopy.c | 1946 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/ |
| H A D | accf_http.c | 379 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/gpl3/gcc/dist/libphobos/libdruntime/core/internal/gc/impl/conservative/ |
| H A D | gc.d | 3994 size_t tocopy; 3997 tocopy = s/(void*).sizeof; 3998 … is_pointer.copyRangeRepeating(offset/(void*).sizeof, tocopy, bitmap, element_size/(void*).sizeof); 4002 tocopy = (s < element_size ? s : element_size)/(void*).sizeof; 4003 is_pointer.copyRange(offset/(void*).sizeof, tocopy, bitmap); 4013 …if (tocopy * (void*).sizeof < s) // better safe than sorry: if allocated more, assume pointers ins… 4015 … debug(PRINTF) printf(" Appending %d pointer bits\n", s/(void*).sizeof - tocopy); 4016 is_pointer.setRange(offset/(void*).sizeof + tocopy, s/(void*).sizeof - tocopy);
|
| /netbsd-src/external/gpl3/binutils/dist/ |
| H A D | ChangeLog.git | 162001 "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".
|