Home
last modified time | relevance | path

Searched refs:old_len (Results 1 – 25 of 52) sorted by relevance

123

/freebsd/contrib/libarchive/tar/
H A Dsubst.c159 size_t old_len; in realloc_strncat() local
162 old_len = 0; in realloc_strncat()
164 old_len = strlen(*str); in realloc_strncat()
166 new_str = malloc(old_len + len + 1); in realloc_strncat()
170 memcpy(new_str, *str, old_len); in realloc_strncat()
171 memcpy(new_str + old_len, append, len); in realloc_strncat()
172 new_str[old_len + len] = '\0'; in realloc_strncat()
181 size_t old_len; in realloc_strcat() local
184 old_len = 0; in realloc_strcat()
186 old_len = strlen(*str); in realloc_strcat()
[all …]
H A Dutil.c316 size_t old_len = strlen(old_pending); local
318 size_t new_len = old_len + newdir_len + 2;
319 if (old_len > SIZE_MAX - newdir_len - 2)
322 if (old_pending[old_len - 1] == '/')
323 old_pending[old_len - 1] = '\0';
/freebsd/contrib/netbsd-tests/rump/modautoload/
H A Dt_modautoload.c37 size_t old_len, new_len; in mountkernfs() local
49 old_len = sizeof(old_autoload); in mountkernfs()
52 &old_autoload, &old_len, in mountkernfs()
/freebsd/usr.bin/gcore/
H A Delfcore.c184 ssize_t n, old_len; in elf_coredump() local
217 sbuf_start_section(sb, &old_len); in elf_coredump()
219 sbuf_end_section(sb, old_len, hdrsize, 0); in elf_coredump()
339 size_t threads, old_len; in elf_putnotes() local
355 sbuf_start_section(sb, &old_len); in elf_putnotes()
393 size = sbuf_end_section(sb, old_len, 1, 0); in elf_putnotes()
408 ssize_t old_len; in elf_putregnote() local
425 sbuf_start_section(sb, &old_len); in elf_putregnote()
427 sbuf_end_section(sb, old_len, sizeof(Elf32_Size), 0); in elf_putregnote()
428 sbuf_start_section(sb, &old_len); in elf_putregnote()
[all …]
/freebsd/contrib/bmake/
H A Dbuf.c92 size_t old_len = buf->len; in Buf_AddBytes() local
95 if (old_len + bytes_len >= buf->cap) { in Buf_AddBytes()
101 end = buf->data + old_len; in Buf_AddBytes()
102 buf->len = old_len + bytes_len; in Buf_AddBytes()
H A Dbuf.h103 size_t old_len = buf->len++; in Buf_AddByte() local
105 if (old_len + 1 >= buf->cap) in Buf_AddByte()
107 end = buf->data + old_len; in Buf_AddByte()
/freebsd/lib/libc/tests/sys/
H A Dmlock_helper.c44 size_t old_len; in vm_max_wired_sysctl() local
50 ATF_REQUIRE_MSG(sysctlbyname(VM_MAX_WIRED, NULL, &old_len, in vm_max_wired_sysctl()
55 ATF_REQUIRE_MSG(sysctlbyname(VM_MAX_WIRED, old_value, &old_len, in vm_max_wired_sysctl()
/freebsd/crypto/openssl/crypto/
H A Dmem.c320 void *CRYPTO_clear_realloc(void *str, size_t old_len, size_t num, in CRYPTO_clear_realloc() argument
329 CRYPTO_clear_free(str, old_len, file, line); in CRYPTO_clear_realloc()
334 if (num < old_len) { in CRYPTO_clear_realloc()
335 OPENSSL_cleanse((char *)str + num, old_len - num); in CRYPTO_clear_realloc()
341 memcpy(ret, str, old_len); in CRYPTO_clear_realloc()
342 CRYPTO_clear_free(str, old_len, file, line); in CRYPTO_clear_realloc()
/freebsd/contrib/tcp_wrappers/
H A Denviron.c127 static char *cmalloc(int new_len, char *old, int old_len) in cmalloc() argument
132 memcpy(new, old, old_len); in cmalloc()
/freebsd/sys/compat/lindebugfs/
H A Dlindebugfs.c678 size_t old_len, new_len; in fops_str_write() local
690 old_len = strlen(old); in fops_str_write()
691 if (*ppos && *ppos != old_len) in fops_str_write()
694 new_len = old_len + write_size; in fops_str_write()
702 memcpy(new, old, old_len); in fops_str_write()
703 if (copy_from_user(new + old_len, buf, write_size) != 0) { in fops_str_write()
/freebsd/contrib/ntp/sntp/libevent/include/event2/
H A Dbuffer_compat.h73 typedef void (*evbuffer_cb)(struct evbuffer *buffer, size_t old_len, size_t new_len, void *arg);
/freebsd/contrib/libevent/include/event2/
H A Dbuffer_compat.h73 typedef void (*evbuffer_cb)(struct evbuffer *buffer, size_t old_len, size_t new_len, void *arg);
/freebsd/lib/virtual_oss/bt/
H A Dbt.c65 int old_len = len; in bt_receive() local
145 return (old_len - len); in bt_receive()
776 int old_len = len; in bt_play_sbc_transfer() local
891 return (old_len); in bt_play_sbc_transfer()
915 int old_len = len; in bt_play_aac_transfer() local
1011 return (old_len); in bt_play_aac_transfer()
/freebsd/usr.bin/top/
H A Ddisplay.c1338 size_t len, old_len; in setup_buffer() local
1355 old_len = strlen(buffer); in setup_buffer()
1356 memcpy(new_buffer, buffer, old_len < len - 1 ? old_len : len - 1); in setup_buffer()
/freebsd/crypto/krb5/src/kadmin/server/
H A Dauth_acl.c107 size_t old_len; in get_line() local
117 old_len = buf.len; in get_line()
125 k5_buf_truncate(&buf, old_len); in get_line()
133 k5_buf_truncate(&buf, old_len + strlen(p)); in get_line()
/freebsd/contrib/tcsh/
H A Ded.xmap.c508 size_t old_len; in Enumerate() local
517 old_len = buf->len; in Enumerate()
530 buf->len = old_len; in Enumerate()
/freebsd/sys/dev/netmap/
H A Dnetmap_pipe.c92 size_t old_len, len; in nm_pipe_alloc() local
102 old_len = sizeof(struct netmap_pipe_adapter *)*na->na_max_pipes; in nm_pipe_alloc()
104 npa = nm_os_realloc(na->na_pipes, len, old_len); in nm_pipe_alloc()
H A Dnetmap_monitor.c209 size_t old_len, len; in nm_monitor_alloc() local
216 old_len = sizeof(struct netmap_kring *)*kring->max_monitors; in nm_monitor_alloc()
218 nm = nm_os_realloc(kring->monitors, len, old_len); in nm_monitor_alloc()
/freebsd/sys/kern/
H A Dsubr_sbuf.c950 sbuf_end_section(struct sbuf *s, ssize_t old_len, size_t pad, int c) in sbuf_end_section() argument
965 if (old_len == -1) { in sbuf_end_section()
969 s->s_sect_len += old_len; in sbuf_end_section()
/freebsd/crypto/openssl/test/helpers/
H A Dquictestlib.c919 size_t old_len; in qtest_fault_prepend_frame() local
930 old_len = fault->pplainio.buf_len; in qtest_fault_prepend_frame()
934 old_len + frame_len))) in qtest_fault_prepend_frame()
937 memmove(buf + frame_len, buf, old_len); in qtest_fault_prepend_frame()
/freebsd/contrib/ofed/libibverbs/
H A Dverbs.c312 size_t old_len; in __ibv_rereg_mr() local
343 old_len = mr->length; in __ibv_rereg_mr()
351 err = ibv_dofork_range(old_addr, old_len); in __ibv_rereg_mr()
/freebsd/sys/dev/ice/
H A Dice_dcb.h228 u16 buf_size, u16 old_len, u16 new_len, u16 offset,
H A Dice_dcb.c172 * @old_len: Length of the Original TLV
184 u16 buf_size, u16 old_len, u16 new_len, u16 offset, in ice_aq_update_lldp_tlv() argument
193 if (offset == 0 || old_len == 0 || new_len == 0) in ice_aq_update_lldp_tlv()
202 cmd->old_len = CPU_TO_LE16(old_len); in ice_aq_update_lldp_tlv()
/freebsd/sys/ufs/ufs/
H A Dufs_extattr.c852 size_t len, old_len; in ufs_extattr_get() local
955 old_len = uio->uio_resid; in ufs_extattr_get()
963 uio->uio_resid = old_len - (len - uio->uio_resid); in ufs_extattr_get()
/freebsd/sys/netinet/
H A Dsctp_output.c11755 uint16_t len, old_len, i; in sctp_add_stream_reset_out() local
11762 old_len = len = SCTP_SIZE32(ntohs(ch->chunk_length)); in sctp_add_stream_reset_out()
11816 ch->chunk_length = htons(len + old_len); in sctp_add_stream_reset_out()
11817 chk->book_size = len + old_len; in sctp_add_stream_reset_out()
11829 uint16_t len, old_len, i; in sctp_add_stream_reset_in() local
11834 old_len = len = SCTP_SIZE32(ntohs(ch->chunk_length)); in sctp_add_stream_reset_in()
11857 ch->chunk_length = htons(len + old_len); in sctp_add_stream_reset_in()
11858 chk->book_size = len + old_len; in sctp_add_stream_reset_in()
11869 uint16_t len, old_len; in sctp_add_stream_reset_tsn() local
11874 old_len = len = SCTP_SIZE32(ntohs(ch->chunk_length)); in sctp_add_stream_reset_tsn()
[all …]

123