/illumos-gate/usr/src/test/libc-tests/tests/random/ |
H A D | getentropy.c | 31 uint8_t buf[128]; local 33 ret = getentropy(buf, sizeof (buf)); 52 ret = getentropy(NULL, sizeof (buf)); 61 ret = getentropy(addr, sizeof (buf));
|
/illumos-gate/usr/src/lib/libast/common/regex/ |
H A D | regerror.c | 59 regerror(int code, const regex_t* p, char* buf, size_t size) argument 72 strncpy(buf, s, size); 73 buf[size - 1] = 0; 76 buf = (char*)s; 77 return strlen(buf) + 1;
|
/illumos-gate/usr/src/lib/libast/common/string/ |
H A D | fmtnum.c | 39 char* buf; local 86 buf = fmtbuf(z = 8); 88 sfsprintf(buf, z, "%lu.%0*lu%s", n, i, r, suf); 90 sfsprintf(buf, z, "%lu%s", n, suf); 91 return buf;
|
/illumos-gate/usr/src/uts/sun/sys/dada/ |
H A D | dada_resource.h | 67 extern struct buf *dcd_alloc_consistent_buf(struct dcd_address *, 68 struct buf *, size_t, uint_t, int (*)(caddr_t), caddr_t); 71 struct dcd_pkt *, struct buf *, int, int, int, int, 76 extern void dcd_free_consistent_buf(struct buf *); 92 extern struct buf *dcd_alloc_consistent_buf();
|
/illumos-gate/usr/src/lib/libc/port/gen/ |
H A D | strerror.c | 66 char *buf; local 70 buf = _libc_gettext((char *)&_sys_errs[_sys_index[errnum]]); 72 buf = _libc_gettext("Unknown error"); 80 if (buflen < (strlen(buf) + 1)) { 83 (void) strcpy(strerrbuf, buf);
|
/illumos-gate/usr/src/uts/common/io/sfxge/ |
H A D | sfxge_vpd.c | 42 void *buf; local 48 buf = kmem_zalloc(size, KM_NOSLEEP); 49 if (buf == NULL) { 54 if ((rc = efx_vpd_read(enp, buf, size)) != 0) 57 if ((rc = efx_vpd_verify(enp, buf, size)) != 0) 63 if ((rc = efx_vpd_get(enp, buf, size, &vpd)) != 0) 70 kmem_free(buf, size); 80 kmem_free(buf, size); 94 void *buf; local 102 buf [all...] |
/illumos-gate/usr/src/boot/sys/boot/userboot/userboot/ |
H A D | copy.c | 55 char buf[4096]; local 60 if (sz > sizeof(buf)) 61 sz = sizeof(buf); 62 s = read(fd, buf, sz); 67 CALLBACK(copyin, buf, va, s);
|
/illumos-gate/usr/src/lib/pkcs11/pkcs11_tpm/common/ |
H A D | asn1.c | 302 CK_BYTE *buf = NULL; local 330 buf = (CK_BYTE *)malloc(len); 331 if (! buf) { 335 buf[0] = 0x02; 336 buf[1] = data_len; 337 (void) memcpy(&buf[2], data, data_len); 340 *ber_int = buf; 345 buf[0] = 0x02; 346 buf[1] = 0x81; 347 buf[ 452 CK_BYTE *buf = NULL; local 604 CK_BYTE *buf = NULL; local 759 CK_BYTE * buf = NULL; local 838 CK_BYTE *buf = NULL; local 895 CK_BYTE *buf = NULL; local 1075 CK_BYTE *buf = NULL; local [all...] |
/illumos-gate/usr/src/cmd/mandoc/ |
H A D | read.c | 57 struct buf *primary; /* buffer currently being parsed */ 58 struct buf *secondary; /* preprocessed copy of input */ 71 static void resize_buf(struct buf *, size_t); 72 static void mparse_buf_r(struct mparse *, struct buf, size_t, int); 74 struct buf *, int *); 76 static void mparse_parse_buffer(struct mparse *, struct buf, 253 resize_buf(struct buf *buf, size_t initial) argument 256 buf->sz = buf 740 mparse_readmem(struct mparse *curp, void *buf, size_t len, const char *file) argument 891 char buf[256]; local [all...] |
/illumos-gate/usr/src/lib/passwdutil/ |
H A D | __set_authtoken_attr.c | 44 void *buf; /* workspace for repository specific funcs */ local 79 buf = NULL; 86 err = rops[i]->getpwnam(name, items, rep, &buf); 90 err = rops[i]->update(items, rep, buf); 93 err = rops[i]->putpwnam(name, oldpw, rep, buf); 98 if (buf) { 99 (void) free(buf); 100 buf = NULL; 111 if (buf) 112 free(buf); [all...] |
/illumos-gate/usr/src/lib/libdtrace_jni/java/src/org/opensolaris/os/dtrace/ |
H A D | ProgramInfo.java | 244 StringBuilder buf = new StringBuilder(); 245 buf.append(ProgramInfo.class.getName()); 246 buf.append("[minimumProbeAttributes = "); 247 buf.append(minimumProbeAttributes); 248 buf.append(", minimumStatementAttributes = "); 249 buf.append(minimumStatementAttributes); 250 buf.append(", matchingProbeCount = "); 251 buf.append(matchingProbeCount); 252 buf.append(']'); 253 return buf [all...] |
/illumos-gate/usr/src/lib/libresolv2/common/isc/ |
H A D | hex.c | 28 isc_gethexstring(unsigned char *buf, size_t len, int count, FILE *fp, argument 68 *buf++ = x; 85 isc_puthexstring(FILE *fp, const unsigned char *buf, size_t buflen, argument 95 fputc(hex[(buf[0]>>4)&0xf], fp); 96 fputc(hex[buf[0]&0xf], fp); 99 buf++; 109 isc_tohex(const unsigned char *buf, size_t buflen, char *t) { argument 111 *t++ = hex[(buf[0]>>4)&0xf]; 112 *t++ = hex[buf[0]&0xf]; 113 buf [all...] |
H A D | ctl_p.c | 78 ctl_bufget(struct ctl_buf *buf, ctl_logfunc logger) { argument 81 REQUIRE(!allocated_p(*buf) && buf->used == 0U); 82 buf->text = memget(MAX_LINELEN); 83 if (!allocated_p(*buf)) { 87 buf->used = 0; 92 ctl_bufput(struct ctl_buf *buf) { argument 94 REQUIRE(allocated_p(*buf)); 95 memput(buf->text, MAX_LINELEN); 96 buf 101 ctl_sa_ntop(const struct sockaddr *sa, char *buf, size_t size, ctl_logfunc logger) argument [all...] |
/illumos-gate/usr/src/lib/libldap5/sources/ldap/common/ |
H A D | friendly.c | 51 char buf[BUFSIZ]; local 66 while ( fgets( buf, sizeof(buf), fp ) != NULL ) { 67 if ( buf[0] != '#' ) 79 while ( fgets( buf, sizeof(buf), fp ) != NULL && i < entries ) { 80 if ( buf[0] == '#' ) 83 if ( (s = strchr( buf, '\n' )) != NULL ) 86 if ( (s = strchr( buf, '\t' )) == NULL ) 109 (*map)[i].f_unfriendly = nsldapi_strdup( buf ); [all...] |
H A D | tmplout.c | 48 static int do_entry2text( LDAP *ld, char *buf, char *base, LDAPMessage *entry, 56 static int do_vals2text( LDAP *ld, char *buf, char **vals, char *label, 60 static int output_label( char *buf, char *label, int width, 62 static int output_dn( char *buf, char *dn, int width, int rdncount, 67 static int searchaction( LDAP *ld, char *buf, char *base, LDAPMessage *entry, 86 char *buf, /* NULL for "use internal" */ 100 return( do_entry2text( ld, buf, NULL, entry, tmpl, defattrs, defvals, 111 char *buf, /* NULL for "use internal" */ 131 return( do_entry2text( ld, buf, base, entry, tmpl, defattrs, defvals, 139 char *buf, /* NUL 84 ldap_entry2text( LDAP *ld, char *buf, LDAPMessage *entry, struct ldap_disptmpl *tmpl, char **defattrs, char ***defvals, writeptype writeproc, void *writeparm, char *eol, int rdncount, unsigned long opts ) argument 109 ldap_entry2html( LDAP *ld, char *buf, LDAPMessage *entry, struct ldap_disptmpl *tmpl, char **defattrs, char ***defvals, writeptype writeproc, void *writeparm, char *eol, int rdncount, unsigned long opts, char *base, char *urlprefix ) argument 137 do_entry2text( LDAP *ld, char *buf, char *base, LDAPMessage *entry, struct ldap_disptmpl *tmpl, char **defattrs, char ***defvals, writeptype writeproc, void *writeparm, char *eol, int rdncount, unsigned long opts, char *urlprefix ) argument 452 char *buf, **fetchattrs, **vals; local 565 ldap_vals2text( LDAP *ld, char *buf, char **vals, char *label, int labelwidth, unsigned long syntaxid, writeptype writeproc, void *writeparm, char *eol, int rdncount ) argument 587 ldap_vals2html( LDAP *ld, char *buf, char **vals, char *label, int labelwidth, unsigned long syntaxid, writeptype writeproc, void *writeparm, char *eol, int rdncount, char *urlprefix ) argument 613 do_vals2text( LDAP *ld, char *buf, char **vals, char *label, int labelwidth, unsigned long syntaxid, writeptype writeproc, void *writeparm, char *eol, int rdncount, char *urlprefix ) argument 813 output_label( char *buf, char *label, int width, writeptype writeproc, void *writeparm, char *eol, int html ) argument 838 output_dn( char *buf, char *dn, int width, int rdncount, writeptype writeproc, void *writeparm, char *eol, char *urlprefix ) argument 918 char buf[26]; local 1036 searchaction( LDAP *ld, char *buf, char *base, LDAPMessage *entry, char *dn, struct ldap_tmplitem *tip, int labelwidth, int rdncount, writeptype writeproc, void *writeparm, char *eol, char *urlprefix ) argument [all...] |
/illumos-gate/usr/src/cmd/mdb/common/libstandctf/ |
H A D | ctf_subr.c | 89 void *buf = mdb_alloc(size, UM_NOSLEEP); local 91 if (buf == NULL) 94 return (buf); 98 ctf_data_free(void *buf, size_t size) argument 100 mdb_free(buf, size); 105 ctf_data_protect(void *buf, size_t size) argument 117 ctf_free(void *buf, size_t size) argument 119 mdb_free(buf, size); 155 ctf_vsnprintf(char *buf, size_t nbytes, const char *format, va_list alist) argument 157 return ((int)mdb_iob_vsnprintf(buf, nbyte [all...] |
/illumos-gate/usr/src/uts/common/syscall/ |
H A D | getpagesizes.c | 37 getpagesizes(int legacy, size_t *buf, int nelem) argument 45 if (nelem == 0 && buf != NULL) { 48 if (nelem == 0 && buf == NULL) { 51 if (buf == NULL) { 61 if (copyout(pgsza, buf, nelem * sizeof (*pgsza)) != 0) { 76 getpagesizes32(int legacy, size32_t *buf, int nelem) argument 86 if (nelem == 0 && buf != NULL) { 104 if (nelem == 0 && buf == NULL) { 108 if (buf == NULL) { 112 if (copyout(pgsza32, buf, nele [all...] |
/illumos-gate/usr/src/uts/common/io/scsi/targets/ |
H A D | sd_xbuf.h | 77 * Primary attribute struct for buf extensions. 86 struct buf *xa_headp; /* FIFO buf queue head ptr */ 87 struct buf *xa_tailp; /* FIFO buf queue tail ptr */ 92 void (*xa_strategy)(struct buf *, ddi_xbuf_t, void *); 96 struct buf *xa_flush_headp; 97 struct buf *xa_flush_tailp; 107 void (*xa_strategy)(struct buf *bp, ddi_xbuf_t xp, void *attr_arg), 115 DDII int ddi_xbuf_qstrategy(struct buf *b [all...] |
/illumos-gate/usr/src/lib/libnsl/rpc/ |
H A D | pmap_prot.c | 52 rpc_inline_t *buf; local 56 buf = XDR_INLINE(xdrs, 4 * BYTES_PER_XDR_UNIT); 57 if (buf == NULL) { 67 IXDR_PUT_U_INT32(buf, objp->pm_prog); 68 IXDR_PUT_U_INT32(buf, objp->pm_vers); 69 IXDR_PUT_U_INT32(buf, objp->pm_prot); 70 IXDR_PUT_U_INT32(buf, objp->pm_port); 74 buf = XDR_INLINE(xdrs, 4 * BYTES_PER_XDR_UNIT); 75 if (buf == NULL) { 85 objp->pm_prog = IXDR_GET_U_INT32(buf); 182 rpc_inline_t *buf; local [all...] |
/illumos-gate/usr/src/cmd/crypt/ |
H A D | crypt.c | 56 char buf[13]; local 61 (void) strncpy(buf, pw, 8); 62 buf[8] = buf[0]; 63 buf[9] = buf[1]; 65 ret = des_crypt(buf, &buf[8]); 72 (void) strncpy(buf, ret, 13); 75 seed = seed*buf[ 112 char *buf; local [all...] |
/illumos-gate/usr/src/cmd/mdb/common/mdb/ |
H A D | mdb_module_load.c | 49 char buf[MAXPATHLEN], *p, *q; local 57 (void) mdb_iob_snprintf(buf, sizeof (buf), "%s", 63 while ((p = strrchr(buf, '.')) != NULL) { 80 name = buf; 110 (void) mdb_iob_snprintf(buf, sizeof (buf), 113 "checking for %s\n", buf); 114 if (access(buf, F_OK) == 0) { 115 return (mdb_module_create(name, buf, [all...] |
/illumos-gate/usr/src/cmd/sgs/librtld_db/demo/common/ |
H A D | dis.c | 69 static char buf[256]; local 83 (void) strcpy(buf, mip->mi_name); 84 (void) strcat(buf, ":"); 86 (void) sprintf(buf, "0x%08lx:", address); 88 buf[0] = '\0'; 108 (void) snprintf(buf, 256, 110 buf, address, _str); 111 return (buf); 116 (void) snprintf(buf, 256, "%s0x%lx:plt(unbound)+0x%lx", 117 buf, addres [all...] |
/illumos-gate/usr/src/lib/gss_mechs/mech_krb5/krb5/asn.1/ |
H A D | asn1_encode.c | 33 asn1_error_code asn1_encode_boolean(asn1buf *buf, asn1_intmax val, argument 43 retval = asn1buf_insert_octet(buf, bval); 47 retval = asn1_make_tag(buf, UNIVERSAL, PRIMITIVE, ASN1_BOOLEAN, length, &partlen); 55 static asn1_error_code asn1_encode_integer_internal(asn1buf *buf, argument 67 retval = asn1buf_insert_octet(buf,(asn1_octet) digit); 74 retval = asn1buf_insert_octet(buf,0); /* of the proper signed-ness */ 78 retval = asn1buf_insert_octet(buf,0xFF); 88 asn1_error_code asn1_encode_integer(asn1buf * buf, asn1_intmax val, argument 94 retval = asn1_encode_integer_internal(buf, val, &partlen); 98 retval = asn1_make_tag(buf,UNIVERSA 127 asn1_encode_unsigned_integer(asn1buf *buf, asn1_uintmax val, unsigned int *retlen) argument 160 encode_bytestring_with_tag(asn1buf *buf, unsigned int len, const void *val, int tag, unsigned int *retlen) argument 178 asn1_encode_oid(asn1buf *buf, unsigned int len, const asn1_octet *val, unsigned int *retlen) argument 186 asn1_encode_octetstring(asn1buf *buf, unsigned int len, const void *val, unsigned int *retlen) argument 223 asn1_encode_generaltime(asn1buf *buf, time_t val, unsigned int *retlen) argument 276 asn1_encode_generalstring(asn1buf *buf, unsigned int len, const void *val, unsigned int *retlen) argument 284 asn1_encode_bitstring(asn1buf *buf, unsigned int len, const void *val, unsigned int *retlen) argument 302 asn1_encode_opaque(asn1buf *buf, unsigned int len, const void *val, unsigned int *retlen) argument 358 encode_nullterm_sequence_of(asn1buf *buf, const void *val, const struct atype_info *type, int can_be_empty, unsigned int *retlen) argument 378 krb5int_asn1_encode_a_thing(asn1buf *buf, const void *val, const struct atype_info *a, unsigned int *retlen) argument 432 encode_a_field(asn1buf *buf, const void *val, const struct field_info *field, unsigned int *retlen) argument 580 encode_fields(asn1buf *buf, const void *val, const struct field_info *fields, size_t nfields, unsigned int optional, unsigned int *retlen) argument 610 just_encode_sequence(asn1buf *buf, const void *val, const struct seq_info *seq, unsigned int *retlen) argument 643 encode_sequence_of(asn1buf *buf, int seqlen, const void *val, const struct atype_info *eltinfo, unsigned int *retlen) argument 678 asn1buf *buf = NULL; local [all...] |
/illumos-gate/usr/src/lib/libcmd/common/ |
H A D | cmd.h | 103 char buf[64]; local 111 buf[0] = '_'; 112 buf[1] = 'b'; 113 buf[2] = '_'; 114 strncpy(buf + 3, s, sizeof(buf) - 4); 115 buf[sizeof(buf) - 1] = 0; 116 if (t = strchr(buf, '.')) 122 if (fun = (Shbltin_f)dlsym(dll, buf [all...] |
/illumos-gate/usr/src/uts/common/io/nxge/ |
H A D | nxge_fflp_hash.c | 30 static void nxge_crc32c_word(uint32_t *crcptr, const uint32_t *buf, int len); 164 nxge_crc32c_byte(uint32_t *crcptr, const uint8_t *buf, int len) argument 172 crc = (crc << 8) ^ crc32c_tab[3][buf[i] ^ (crc >> 24)]; 174 crc = (crc >> 8) ^ crc32c_tab[0][buf[i] ^ (crc & 0xff)]; 185 nxge_crc_ccitt_byte(uint16_t *crcptr, const uint8_t *buf, int len) argument 194 crc = (crc << 8) ^ crc_ccitt_tab[3][buf[i] ^ (crc >> 8)]; 196 crc = (crc << 8) ^ crc_ccitt_tab[0][buf[i] ^ (crc >> 8)]; 210 nxge_crc32c_word(uint32_t *crcptr, const uint32_t *buf, int len) argument 217 w = crc ^ buf[i]; 236 nxge_crc_ccitt(uint16_t crc16, const uint8_t *buf, in argument 255 nxge_crc32c(uint32_t crc32, const uint8_t *buf, int len) argument 307 uint8_t *buf; local 334 uint32_t *buf; local 364 uint8_t *buf; local [all...] |