| /src/contrib/ncurses/ncurses/tinfo/ |
| H A D | comp_expand.c | 66 int bufp; in _nc_tic_expand() local 94 bufp = 0; in _nc_tic_expand() 97 buffer[bufp++] = *str++; in _nc_tic_expand() 109 _nc_SPRINTF(buffer + bufp, _nc_SLIMIT(P_LIMIT(bufp)) in _nc_tic_expand() 111 bufp += (int) strlen(buffer + bufp); in _nc_tic_expand() 114 buffer[bufp++] = *str; in _nc_tic_expand() 134 buffer[bufp++] = S_QUOTE; in _nc_tic_expand() 137 buffer[bufp++] = '\\'; in _nc_tic_expand() 138 buffer[bufp++] = (char) ch; in _nc_tic_expand() 139 buffer[bufp++] = S_QUOTE; in _nc_tic_expand() [all …]
|
| H A D | lib_termcap.c | 98 NCURSES_SP_NAME(tgetent) (NCURSES_SP_DCLx char *bufp, const char *name) in tgetent() argument 131 bool same_result = (MyCache[n].last_used && MyCache[n].last_bufp == bufp); in tgetent() 197 LAST_BUF = bufp; in tgetent() 216 if (bufp && _nc_termcap[0]) in tgetent() 217 strncpy(bufp, _nc_termcap, 1024); in tgetent() 225 tgetent(char *bufp, const char *name) in tgetent() argument 227 return NCURSES_SP_NAME(tgetent) (CURRENT_SCREEN, bufp, name); in tgetent()
|
| /src/lib/libc/db/hash/ |
| H A D | hash_bigkey.c | 82 __big_insert(HTAB *hashp, BUFHEAD *bufp, const DBT *key, const DBT *val) in __big_insert() argument 90 cp = bufp->page; /* Character pointer of p. */ in __big_insert() 112 bufp = __add_ovflpage(hashp, bufp); in __big_insert() 113 if (!bufp) in __big_insert() 142 p = (u_int16_t *)bufp->page; in __big_insert() 143 cp = bufp->page; in __big_insert() 144 bufp->flags |= BUF_MOD; in __big_insert() 168 bufp = __add_ovflpage(hashp, bufp); in __big_insert() 169 if (!bufp) in __big_insert() 171 cp = bufp->page; in __big_insert() [all …]
|
| H A D | hash_page.c | 122 __delpair(HTAB *hashp, BUFHEAD *bufp, int ndx) in __delpair() argument 127 bp = (u_int16_t *)bufp->page; in __delpair() 131 return (__big_delete(hashp, bufp)); in __delpair() 141 char *src = bufp->page + (int)OFFSET(bp); in __delpair() 170 bufp->flags |= BUF_MOD; in __delpair() 280 BUFHEAD *bufp; /* Buffer header for ino */ in ugly_split() local 291 bufp = old_bufp; in ugly_split() 302 new_bufp, bufp, bufp->addr, obucket, &ret)) in ugly_split() 312 bufp = ret.nextp; in ugly_split() 313 if (!bufp) in ugly_split() [all …]
|
| H A D | hash.c | 576 BUFHEAD *bufp, *save_bufp; in hash_access() local 624 bufp = rbufp; in hash_access() 626 __find_last_page(hashp, &bufp))) { in hash_access() 628 rbufp = bufp; in hash_access() 631 rbufp = __get_buf(hashp, pageno, bufp, 0); in hash_access() 702 BUFHEAD *bufp; in hash_seq() local 723 if (!(bufp = hashp->cpage)) { in hash_seq() 727 bufp = __get_buf(hashp, bucket, NULL, 0); in hash_seq() 728 if (!bufp) in hash_seq() 730 hashp->cpage = bufp; in hash_seq() [all …]
|
| /src/sys/opencrypto/ |
| H A D | cryptodeflate.c | 90 struct deflate_buf *bufh, *bufp; in deflate_global() local 94 bufh = bufp = NULL; in deflate_global() 114 bufh = bufp = malloc(sizeof(*bufp) + (size_t)(size * i), in deflate_global() 116 if (bufp == NULL) { in deflate_global() 121 bufp->next = NULL; in deflate_global() 122 bufp->size = size * i; in deflate_global() 130 zbuf.next_out = bufp->data; in deflate_global() 131 zbuf.avail_out = bufp->size; in deflate_global() 173 bufp->next = p; in deflate_global() 174 bufp = p; in deflate_global() [all …]
|
| /src/crypto/krb5/src/lib/krb5/krb/ |
| H A D | serialize.c | 34 krb5_ser_pack_int32(krb5_int32 iarg, krb5_octet **bufp, size_t *remainp) in krb5_ser_pack_int32() argument 37 store_32_be(iarg, *bufp); in krb5_ser_pack_int32() 38 *bufp += sizeof(krb5_int32); in krb5_ser_pack_int32() 51 krb5_ser_pack_int64(int64_t iarg, krb5_octet **bufp, size_t *remainp) in krb5_ser_pack_int64() argument 54 store_64_be(iarg, (unsigned char *)*bufp); in krb5_ser_pack_int64() 55 *bufp += sizeof(int64_t); in krb5_ser_pack_int64() 67 krb5_ser_pack_bytes(krb5_octet *ostring, size_t osize, krb5_octet **bufp, size_t *remainp) in krb5_ser_pack_bytes() argument 70 memcpy(*bufp, ostring, osize); in krb5_ser_pack_bytes() 71 *bufp += osize; in krb5_ser_pack_bytes() 83 krb5_ser_unpack_int32(krb5_int32 *intp, krb5_octet **bufp, size_t *remainp) in krb5_ser_unpack_int32() argument [all …]
|
| H A D | chk_trans.c | 175 char *p, *bufp; in foreach_realm() local 206 bufp = buf; in foreach_realm() 209 *bufp++ = *p; in foreach_realm() 210 if (bufp == buf+sizeof(buf)) in foreach_realm() 216 if (bufp != buf) { in foreach_realm() 217 this_component.length = bufp - buf; in foreach_realm() 239 bufp = buf; in foreach_realm() 251 } else if (*p == ' ' && bufp == buf) { in foreach_realm() 258 *bufp++ = *p; in foreach_realm() 259 if (bufp == buf+sizeof(buf)) in foreach_realm() [all …]
|
| /src/lib/libc/stdio/ |
| H A D | open_memstream.c | 47 char **bufp; member 64 buf = realloc(*ms->bufp, newsize + 1); in memstream_grow() 71 *ms->bufp = buf; in memstream_grow() 100 memcpy(*ms->bufp + ms->offset, buf, tocopy); in memstream_write() 173 open_memstream(char **bufp, size_t *sizep) in open_memstream() argument 179 if (bufp == NULL || sizep == NULL) { in open_memstream() 183 *bufp = calloc(1, 1); in open_memstream() 184 if (*bufp == NULL) in open_memstream() 189 free(*bufp); in open_memstream() 190 *bufp = NULL; in open_memstream() [all …]
|
| H A D | open_wmemstream.c | 47 wchar_t **bufp; member 65 buf = reallocarray(*ms->bufp, newsize + 1, sizeof(wchar_t)); in wmemstream_grow() 72 *ms->bufp = buf; in wmemstream_grow() 141 charlen = mbrtowc(*ms->bufp + ms->offset, buf, len, in wmemstream_write() 234 open_wmemstream(wchar_t **bufp, size_t *sizep) in open_wmemstream() argument 240 if (bufp == NULL || sizep == NULL) { in open_wmemstream() 244 *bufp = calloc(1, sizeof(wchar_t)); in open_wmemstream() 245 if (*bufp == NULL) in open_wmemstream() 250 free(*bufp); in open_wmemstream() 251 *bufp = NULL; in open_wmemstream() [all …]
|
| /src/sbin/ipf/libipf/ |
| H A D | ipft_pc.c | 174 static char *bufp = NULL; in ipcap_read() local 180 if (!bufp) in ipcap_read() 181 bufp = malloc(i); in ipcap_read() 183 bufp = realloc(bufp, i); in ipcap_read() 185 if (read(pfd, bufp, i) != i) in ipcap_read() 189 bcopy(bufp, buf, n); in ipcap_read() 201 static char *bufp = NULL; in ipcap_readip() local 221 if (!bufp) in ipcap_readip() 222 bufp = malloc(i); in ipcap_readip() 224 bufp = realloc(bufp, i); in ipcap_readip() [all …]
|
| /src/contrib/ntp/libparse/ |
| H A D | ieee754io.c | 103 unsigned char *bufp, in fmt_hex() argument 114 snprintf(hex, sizeof(hex), "%02x", bufp[i]); in fmt_hex() 125 unsigned char *bufp, in get_byte() argument 132 val = *(bufp + offset[*fieldindex]); in get_byte() 135 …printf("fetchieee754: getbyte(0x%08x, %d) = 0x%02x\n", (unsigned int)(bufp)+offset[*fieldindex], *… in get_byte() 144 unsigned char *bufp, in put_byte() argument 150 *(bufp + offsets[*fieldindex]) = val; in put_byte() 167 unsigned char *bufp = *buffpp; in fetch_ieee754() local 206 val = get_byte(bufp, offsets, &fieldindex); /* fetch sign byte & first part of characteristic */ in fetch_ieee754() 211 …val = get_byte(bufp, offsets, &fieldindex); /* fetch rest of characteristic and start of mantissa … in fetch_ieee754() [all …]
|
| /src/kerberos5/lib/libgssapi_krb5/ |
| H A D | pname_to_uid.c | 42 char lname[MAXLOGNAME + 1], buf[1024], *bufp; in _gsskrb5_pname_to_uid() local 61 bufp = buf; in _gsskrb5_pname_to_uid() 63 bufp = malloc(buflen); in _gsskrb5_pname_to_uid() 64 if (bufp == NULL) in _gsskrb5_pname_to_uid() 66 error = getpwnam_r(lname, &pwd, bufp, buflen, &pw); in _gsskrb5_pname_to_uid() 70 free(bufp); in _gsskrb5_pname_to_uid() 81 if (bufp != NULL && buflen > sizeof(buf)) in _gsskrb5_pname_to_uid() 82 free(bufp); in _gsskrb5_pname_to_uid()
|
| /src/sys/powerpc/powernv/ |
| H A D | opal_dbg.c | 101 uint64_t lenp, bufp; in uart_opal_dbg_getc() local 106 bufp = vtophys(&c); in uart_opal_dbg_getc() 109 bufp = (uint64_t)&c; in uart_opal_dbg_getc() 112 err = opal_call(OPAL_CONSOLE_READ, termnum, lenp, bufp); in uart_opal_dbg_getc() 127 uint64_t lenp, bufp; in uart_opal_dbg_putc() local 133 bufp = vtophys(&ch); in uart_opal_dbg_putc() 136 bufp = (uint64_t)&ch; in uart_opal_dbg_putc() 140 err = opal_call(OPAL_CONSOLE_WRITE, termnum, lenp, bufp); in uart_opal_dbg_putc()
|
| /src/contrib/libpcap/ |
| H A D | dlpisubs.c | 144 int count, u_char *bufp, int len) in pcap_process_pkts() argument 163 ep = bufp + len; in pcap_process_pkts() 167 while (bufp < ep) { in pcap_process_pkts() 182 p->bp = bufp; in pcap_process_pkts() 183 p->cc = ep - bufp; in pcap_process_pkts() 188 if ((long)bufp & 3) { in pcap_process_pkts() 190 memcpy(sbp, bufp, sizeof(*sbp)); in pcap_process_pkts() 193 sbp = (struct sb_hdr *)bufp; in pcap_process_pkts() 195 pk = bufp + sizeof(*sbp); in pcap_process_pkts() 196 bufp += sbp->sbh_totlen; in pcap_process_pkts() [all …]
|
| /src/contrib/sendmail/src/ |
| H A D | usersmtp.c | 2061 char *bufp; local 2128 bufp = &optbuf[strlen(optbuf)]; 2133 bufp = optbuf; 2139 (void) sm_snprintf(bufp, SPACELEFT(optbuf, bufp), 2141 bufp += strlen(bufp); 2155 SPACELEFT(optbuf, bufp) > strlen(bodytype) + 7) 2157 (void) sm_snprintf(bufp, SPACELEFT(optbuf, bufp), 2159 bufp += strlen(bufp); 2192 SPACELEFT(optbuf, bufp) > strlen(e->e_envid) + 7) 2194 (void) sm_snprintf(bufp, SPACELEFT(optbuf, bufp), [all …]
|
| /src/usr.sbin/ppp/ |
| H A D | vjcomp.c | 117 u_char *bufp; in VjUncompressTcp() local 128 bufp = MBUF_CTOP(bp); in VjUncompressTcp() 129 len = sl_uncompress_tcp(&bufp, len, type, &ipcp->vj.cslc, &ipcp->vj.slstat, in VjUncompressTcp() 147 bufp = work + MAX_HDR; in VjUncompressTcp() 148 bp = mbuf_Read(bp, bufp, rlen); in VjUncompressTcp() 149 len = sl_uncompress_tcp(&bufp, olen, type, &ipcp->vj.cslc, &ipcp->vj.slstat, in VjUncompressTcp() 158 bp = m_prepend(bp, bufp, len, 0); in VjUncompressTcp()
|
| H A D | pred.c | 181 u_char bufp[MAX_MTU + 2]; in Pred1Output() local 187 cp = bufp; in Pred1Output() 193 fcs = hdlc_Fcs(bufp, 2 + orglen); in Pred1Output() 196 len = compress(state, bufp + 2, wp, orglen); in Pred1Output() 204 memcpy(wp, bufp + 2, orglen); in Pred1Output() 223 u_char *bufp; in Pred1Input() local 229 pp = bufp = MBUF_CTOP(wp); in Pred1Input() 262 fcs = hdlc_Fcs(bufp, wp->m_len = pp - bufp); in Pred1Input()
|
| /src/crypto/openssl/crypto/asn1/ |
| H A D | f_int.c | 56 unsigned char *bufp; in a2i_ASN1_INTEGER() local 89 bufp = (unsigned char *)buf; in a2i_ASN1_INTEGER() 92 if ((bufp[0] == '0') && (bufp[1] == '0')) { in a2i_ASN1_INTEGER() 93 bufp += 2; in a2i_ASN1_INTEGER() 116 m = OPENSSL_hexchar2int(bufp[k + n]); in a2i_ASN1_INTEGER()
|
| /src/usr.sbin/crunch/crunchide/ |
| H A D | exec_elf32.c | 92 void *bufp; member 327 layoutp[r].bufp = NULL; in hide() 351 layoutp[i].bufp = shdrp; in hide() 356 layoutp[i].bufp = shstrtabp; in hide() 366 layoutp[i].bufp = xmalloc(size, fn, in hide() 368 if (layoutp[i].bufp == NULL) in hide() 370 if ((size_t)xreadatoff(fd, layoutp[i].bufp, off, size, fn) != in hide() 376 symtabp = layoutp[i].bufp; in hide() 378 strtabp = layoutp[i].bufp; in hide() 452 buf = layoutp[i].bufp; in hide() [all …]
|
| /src/contrib/ntp/libntp/ |
| H A D | recvbuff.c | 110 recvbuf_t * bufp; in create_buffers() local 139 bufp = calloc(chunk, sizeof(*bufp)); in create_buffers() 140 if (!bufp) { in create_buffers() 143 chunk, (u_long)sizeof(*bufp) * chunk); in create_buffers() 147 for (i = chunk; i; --i,++bufp) { in create_buffers() 148 LINK_SLIST(free_recv_list, bufp, link); in create_buffers()
|
| /src/sbin/dhclient/ |
| H A D | parse.c | 249 unsigned char *bufp = buf, *s = NULL; in parse_numeric_aggregate() local 256 if (!bufp && *max) { in parse_numeric_aggregate() 257 lbufp = bufp = malloc(*max * size / 8); in parse_numeric_aggregate() 258 if (!bufp) in parse_numeric_aggregate() 261 s = bufp; in parse_numeric_aggregate() 314 bufp = malloc(count * size / 8); in parse_numeric_aggregate() 315 if (!bufp) in parse_numeric_aggregate() 317 s = bufp + count - size / 8; in parse_numeric_aggregate() 329 return (bufp); in parse_numeric_aggregate()
|
| /src/contrib/ntp/ntpd/ |
| H A D | ntp_ppsdev.c | 220 char *bufp, *endp, *scan; in getPpsTuple() local 225 if (NULL == (bufp = readFileAt(fdDir, "path"))) in getPpsTuple() 227 if ((-1 == stat(bufp, &sb)) || !S_ISCHR(sb.st_mode)) in getPpsTuple() 230 free(bufp); in getPpsTuple() 236 if (NULL == (bufp = readFileAt(fdDir, "dev"))) in getPpsTuple() 238 dmaj = strtoul((scan = bufp), &endp, 10); in getPpsTuple() 248 free(bufp); in getPpsTuple()
|
| /src/lib/libufs/ |
| H A D | sblock.c | 178 static int use_pread(void *devfd, off_t loc, void **bufp, int size); 225 use_pread(void *devfd, off_t loc, void **bufp, int size) in use_pread() argument 230 BUF_MALLOC(bufp, NULL, size); in use_pread() 231 if (*bufp == NULL) in use_pread() 233 if (pread(fd, *bufp, size, loc) != size) in use_pread()
|
| /src/usr.bin/comm/ |
| H A D | comm.c | 204 show(FILE *fp, const char *fn, const char *offset, char **bufp, size_t *buflenp) in show() argument 211 (void)printf("%s%s\n", offset, *bufp); in show() 212 if ((n = getline(bufp, buflenp, fp)) < 0) in show() 214 if (n > 0 && offset != NULL && (*bufp)[n - 1] == '\n') in show() 215 (*bufp)[n - 1] = '\0'; in show()
|