/titanic_41/usr/src/lib/pkcs11/pkcs11_tpm/common/ |
H A D | asn1.c | 303 CK_ULONG len; in ber_encode_INTEGER() local 315 len = 1 + 1 + data_len; in ber_encode_INTEGER() 317 len = 1 + (1 + 1) + data_len; in ber_encode_INTEGER() 319 len = 1 + (1 + 2) + data_len; in ber_encode_INTEGER() 321 len = 1 + (1 + 3) + data_len; in ber_encode_INTEGER() 326 *ber_int_len = len; in ber_encode_INTEGER() 330 buf = (CK_BYTE *)malloc(len); in ber_encode_INTEGER() 339 *ber_int_len = len; in ber_encode_INTEGER() 350 *ber_int_len = len; in ber_encode_INTEGER() 362 *ber_int_len = len; in ber_encode_INTEGER() [all …]
|
/titanic_41/usr/src/lib/libmp/common/ |
H A D | madd.c | 34 cval = _mp_xalloc(a->len + 1, "m_add"); in m_add() 36 for (i = 0; i < b->len; i++) { in m_add() 46 for (; i < a->len; i++) { in m_add() 57 c->len = i + 1; in m_add() 59 c->len = a->len; in m_add() 62 if (c->len == 0) { in m_add() 73 x.len = y.len = 0; in mp_madd() 78 if (x.len >= 0) { in mp_madd() 79 if (y.len >= 0) { in mp_madd() 80 if (x.len >= y.len) { in mp_madd() [all …]
|
H A D | mdiv.c | 37 x.len = y.len = 0; in mp_mdiv() 40 if (x.len < 0) { in mp_mdiv() 42 x.len = -x.len; in mp_mdiv() 44 if (y.len < 0) { in mp_mdiv() 46 y.len = -y.len; in mp_mdiv() 52 q->len = -q->len; in mp_mdiv() 53 r->len = -r->len; in mp_mdiv() 158 u.len = v.len = x.len = w.len = 0; in m_div() 159 if (b->len == 0) { in m_div() 163 if (b->len == 1) { in m_div() [all …]
|
H A D | msqrt.c | 32 a0.len = junk.len = y.len = 0; in mp_msqrt() 33 if (a->len < 0) in mp_msqrt() 35 if (a->len == 0) { in mp_msqrt() 36 b->len = 0; in mp_msqrt() 37 r->len = 0; in mp_msqrt() 40 if (a->len % 2 == 1) in mp_msqrt() 41 x.len = (1 + a->len) / 2; in mp_msqrt() 43 x.len = 1 + a->len / 2; in mp_msqrt() 44 x.val = _mp_xalloc(x.len, "mp_msqrt"); in mp_msqrt() 45 for (j = 0; j < x.len; x.val[j++] = 0) in mp_msqrt() [all …]
|
H A D | mult.c | 36 if (a->len == 0 || b->len == 0) { in mp_mult() 41 x.len = y.len = 0; in mp_mult() 44 if (a->len < 0) { in mp_mult() 45 x.len = -x.len; in mp_mult() 48 if (b->len < 0) { in mp_mult() 49 y.len = -y.len; in mp_mult() 53 if (x.len < y.len) { in mp_mult() 59 c->len = -c->len; in mp_mult() 60 if (c->len == 0) in mp_mult() 86 alen = a->len; in m_mult() [all …]
|
/titanic_41/usr/src/uts/common/io/audio/impl/ |
H A D | audio_format.c | 48 do_src(audio_stream_t *sp, void *p1, void *p2, int len, int nchan) in do_src() argument 62 p1, p2, len, size, nchan, ch); in do_src() 88 cnv_srconly(audio_stream_t *sp, int len) in cnv_srconly() argument 96 len = do_src(sp, src, dst, len, sp->s_cnv_src_nchan); in cnv_srconly() 101 return (len); in cnv_srconly() 105 cnv_s24oe(audio_stream_t *sp, int len) in cnv_s24oe() argument 112 for (int i = len * sp->s_cnv_src_nchan; i; i--) { in cnv_s24oe() 117 return (len); in cnv_s24oe() 122 cnv_from_s8(audio_stream_t *sp, int len) in cnv_from_s8() argument 129 for (int i = len * sp->s_cnv_src_nchan; i; i--) in cnv_from_s8() [all …]
|
/titanic_41/usr/src/cmd/bnu/ |
H A D | eio.c | 136 int len; local 175 while ((len = read( fd1, bufr, EBUFSIZ )) > 0) { 176 DEBUG(9, "ewrdata writing %d ...", len); 178 bytes += len; 180 ret = (*Write)(fn, bufr, (unsigned) len); 183 if (ret != len) 185 if ((msglen -= len) <= 0) 188 if (len < 0 || (len == 0 && msglen != 0)) return(FAIL); 208 int len; local 219 ret = len = 0; [all …]
|
H A D | gio.c | 96 int len, i; local 107 len = strlen(bufr) + 1; 108 if ((i = len % xpacksize) != 0) { 109 len = len + xpacksize - i; 110 bufr[len - 1] = '\0'; 112 gwrblk(bufr, len); 122 unsigned len; local 127 len = pkread(str, packsize); 128 if (len == 0) 130 str += len; [all …]
|
H A D | xio.c | 112 int len; local 119 if( (len = (*Read)(fn, str, XBUFSIZ)) == 0) 121 if (len < 0) { 125 str += len; 147 int len, ret; local 153 while ((len = read( fd1, bufr, XBUFSIZ )) > 0) { 154 bytes += len; 156 ret = (*Write)(fn, bufr, len); 157 if (ret != len) { 160 if (len != XBUFSIZ) [all …]
|
/titanic_41/usr/src/uts/intel/io/drm/ |
H A D | i915_gem_debug.c | 101 unsigned int len = 1, i; in decode_mi() local 105 len = (data[0] & 0x000000ff) + 2; in decode_mi() 106 if (len < opcodes_mi[opcode].min_len || in decode_mi() 107 len > opcodes_mi[opcode].max_len) in decode_mi() 114 for (i = 1; i < len; i++) { in decode_mi() 116 BUFFER_FAIL(count, len, opcodes_mi[opcode].name); in decode_mi() 120 return len; in decode_mi() 132 unsigned int opcode, len; in decode_2d() local 176 len = (data[0] & 0x000000ff) + 2; in decode_2d() 177 if (len != 6) in decode_2d() [all …]
|
/titanic_41/usr/src/lib/gss_mechs/mech_krb5/support/ |
H A D | utf8_conv.c | 141 ssize_t len; in krb5int_utf8s_to_ucs2s() local 150 len = k5_utf8s_to_ucs2s(*ucs2s, utf8s, chars + 1, 0); in krb5int_utf8s_to_ucs2s() 151 if (len < 0) { in krb5int_utf8s_to_ucs2s() 170 ssize_t len; in krb5int_utf8cs_to_ucs2s() local 179 len = k5_utf8s_to_ucs2s(*ucs2s, utf8s, chars + 1, 0); in krb5int_utf8cs_to_ucs2s() 180 if (len < 0) { in krb5int_utf8cs_to_ucs2s() 198 ssize_t len; in krb5int_utf8s_to_ucs2les() local 208 len = k5_utf8s_to_ucs2s((krb5_ucs2 *)*ucs2les, utf8s, chars + 1, 1); in krb5int_utf8s_to_ucs2les() 209 if (len < 0) { in krb5int_utf8s_to_ucs2les() 228 ssize_t len; in krb5int_utf8cs_to_ucs2les() local [all …]
|
/titanic_41/usr/src/cmd/cmd-inet/usr.bin/pppd/ |
H A D | cbcp.c | 57 static void cbcp_input __P((int unit, u_char *pkt, int len)); 59 static int cbcp_printpkt __P((u_char *pkt, int len, 88 static void cbcp_recvreq __P((cbcp_state *us, u_char *pckt, int len)); 89 static void cbcp_recvack __P((cbcp_state *us, u_char *pckt, int len)); 90 static void cbcp_send __P((cbcp_state *us, int code, u_char *buf, int len)); 146 u_short len; local 159 GETSHORT(len, inp); 161 if (len > pktlen) { 162 error("CBCP packet: invalid length (%d > %d)", len, pktlen); 166 len -= CBCP_MINLEN; [all …]
|
/titanic_41/usr/src/lib/libresolv2/common/nameser/ |
H A D | ns_print.c | 56 static void addlen(size_t len, char **buf, size_t *buflen); 57 static int addstr(const char *src, size_t len, 59 static int addtab(size_t len, size_t target, int spaced, 114 int len, x; in ns_sprintrrf() local 122 len = prune_origin(name, origin); in ns_sprintrrf() 125 } else if (len == 0) { in ns_sprintrrf() 128 T(addstr(name, len, &buf, &buflen)); in ns_sprintrrf() 132 name[len] == '\0')) && name[len - 1] != '.') { in ns_sprintrrf() 135 len++; in ns_sprintrrf() 137 T(spaced = addtab(len, 24, spaced, &buf, &buflen)); in ns_sprintrrf() [all …]
|
/titanic_41/usr/src/common/smbsrv/ |
H A D | smb_utf8.c | 80 int len; in smb_mbstowcs() local 84 len = smb_mbtowc(wcstring, mbstring, MTS_MB_CHAR_MAX); in smb_mbstowcs() 85 if (len < 0) { in smb_mbstowcs() 94 mbstring += len; in smb_mbstowcs() 217 size_t len; in smb_wcstombs() local 224 len = smb_wctomb(mbstring, wide_char); in smb_wcstombs() 230 mbstring += len; in smb_wcstombs() 231 nbytes -= len; in smb_wcstombs() 236 if ((len = smb_wctomb(buf, wide_char)) > nbytes) { in smb_wcstombs() 241 bcopy(buf, mbstring, len); in smb_wcstombs() [all …]
|
/titanic_41/usr/src/lib/libnisdb/ |
H A D | db_item.cc | 55 len = n; in item() 56 if ((value = new char[len]) == NULL) in item() 59 (void) memcpy(value, str, len); in item() 66 len = model->len; in item() 67 if ((value = new char[len]) == NULL) in item() 71 (void) memcpy(value, model->value, len); in item() 79 for (i = 0; i < len; i++) in print() 88 return ((len == other->len) && in equal() 89 (!strncasecmp(value, other->value, len))); in equal() 91 return ((len == other->len) && in equal() [all …]
|
/titanic_41/usr/src/uts/common/crypto/api/ |
H A D | kcf_random.c | 124 static void rndc_getbytes(uint8_t *ptr, size_t len); 224 rngprov_seed(uint8_t *buf, int len, uint_t entropy_est, uint32_t flags) in rngprov_seed() argument 230 (void) KCF_PROV_SEED_RANDOM(pd, pd->pd_sid, buf, len, in rngprov_seed() 326 rngprov_getbytes_nblk(uint8_t *ptr, size_t len) in rngprov_getbytes_nblk() argument 375 pd->pd_sid, ptr, len, 0, 0); in rngprov_getbytes_nblk() 388 blen = min(MINEXTRACTBYTES, len); in rngprov_getbytes_nblk() 390 if (len < MINEXTRACTBYTES) in rngprov_getbytes_nblk() 391 rndc_addbytes(rndbuf + len, in rngprov_getbytes_nblk() 392 MINEXTRACTBYTES - len); in rngprov_getbytes_nblk() 394 len -= blen; in rngprov_getbytes_nblk() [all …]
|
/titanic_41/usr/src/cmd/sendmail/db/db/ |
H A D | db_ret.c | 45 u_int32_t len; local 57 len = LEN_HKEYDATA(h, dbp->pgsize, indx); 69 len = bk->len; 76 return (__db_retcopy(dbt, data, len, memp, memsize, 88 __db_retcopy(dbt, data, len, memp, memsize, db_malloc) in __db_retcopy() argument 91 u_int32_t len; 101 if (len > dbt->doff) { 102 len -= dbt->doff; 103 if (len > dbt->dlen) 104 len = dbt->dlen; [all …]
|
/titanic_41/usr/src/cmd/tail/ |
H A D | read.c | 60 int ch, len, tlen; in bytes() local 82 for (t = p - 1, len = 0; t >= sp; --t, ++len) in bytes() 83 if (*t == '\n' && len) { in bytes() 84 WR(t + 1, len); in bytes() 85 len = 0; in bytes() 88 tlen = len; in bytes() 89 for (t = ep - 1, len = 0; t >= p; --t, ++len) in bytes() 91 if (len) { in bytes() 92 WR(t + 1, len); in bytes() 93 len = 0; in bytes() [all …]
|
/titanic_41/usr/src/lib/libc/port/locale/ |
H A D | strptime.c | 60 int i, len, recurse = 0; in __strptime() local 106 len = 2; in __strptime() 107 for (i = 0; len && isdigit(*buf); buf++) { in __strptime() 110 len--; in __strptime() 182 len = 3; in __strptime() 183 for (i = 0; len && isdigit(*buf); buf++) { in __strptime() 186 len--; in __strptime() 202 len = 2; in __strptime() 203 for (i = 0; len && isdigit(*buf); buf++) { in __strptime() 206 len--; in __strptime() [all …]
|
/titanic_41/usr/src/uts/common/io/ |
H A D | sysevent.c | 69 sysevent_isstrend(char *string, size_t len) in sysevent_isstrend() argument 72 if (len > 0) { in sysevent_isstrend() 73 return (string[len - 1] == '\0' ? 1 : 0); in sysevent_isstrend() 169 if (uargs.ev.len > MAX_EV_SIZE_LEN) in sysevent_publish() 186 ev = evch_usrallocev(uargs.ev.len, uargs.flags); in sysevent_publish() 188 if (copyin((void *)(uintptr_t)uargs.ev.name, ev, uargs.ev.len) != 0) { in sysevent_publish() 219 if (uargs.chan_name.len > MAX_CHNAME_LEN) in sysevent_chan_open() 222 chan_name = kmem_alloc(uargs.chan_name.len, KM_SLEEP); in sysevent_chan_open() 225 uargs.chan_name.len) != 0) { in sysevent_chan_open() 226 kmem_free(chan_name, uargs.chan_name.len); in sysevent_chan_open() [all …]
|
/titanic_41/usr/src/lib/libipmi/common/ |
H A D | ipmi_fru.c | 125 uint8_t len, typelen; in ipmi_fru_parse_product() local 144 len = BITX(typelen, 5, 0); in ipmi_fru_parse_product() 145 ipmi_decode_string((typelen >> 6), len, tmp+1, buf->ifpi_manuf_name); in ipmi_fru_parse_product() 146 tmp += len + 1; in ipmi_fru_parse_product() 149 len = BITX(typelen, 5, 0); in ipmi_fru_parse_product() 150 ipmi_decode_string((typelen >> 6), len, tmp+1, in ipmi_fru_parse_product() 152 tmp += len + 1; in ipmi_fru_parse_product() 155 len = BITX(typelen, 5, 0); in ipmi_fru_parse_product() 156 ipmi_decode_string((typelen >> 6), len, tmp+1, buf->ifpi_part_number); in ipmi_fru_parse_product() 157 tmp += len + 1; in ipmi_fru_parse_product() [all …]
|
/titanic_41/usr/src/cmd/listen/ |
H A D | nstoa.c | 111 addr->len = 0; 123 addr->len = dobase(++str, sbuf, HEX); 128 addr->len = dobase(++str, sbuf, OCT); 132 addr->len = dostring(str, sbuf, 0); 136 addr->len = dostring(--str, sbuf, quote); 145 addr->len = dostring(str, sbuf, quote); 148 if (addr->len == 0) { /* Error in conversion */ 153 if ((addr->buf = xfer(addr->buf, sbuf, addr->len, addr->maxlen)) == NULL) 173 int oc, ch, len = 0; local 178 if (len >= SBUFSIZE) { [all …]
|
/titanic_41/usr/src/uts/common/zmod/ |
H A D | inftrees.c | 42 unsigned len; /* a code's length in bits */ local 109 for (len = 0; len <= MAXBITS; len++) 110 count[len] = 0; 134 for (len = 1; len <= MAXBITS; len++) { 136 left -= count[len]; 144 for (len = 1; len < MAXBITS; len++) 145 offs[len + 1] = offs[len] + count[len]; 205 len = min; /* starting code length */ 220 this.bits = (unsigned char)(len - drop); 235 incr = 1U << (len - drop); [all …]
|
/titanic_41/usr/src/uts/common/ktli/ |
H A D | t_kconnect.c | 71 int len; in t_kconnect() local 98 while (!(bp = allocb_cred(msgsz + sndcall->addr.len + sndcall->opt.len, in t_kconnect() 100 if (strwaitbuf(msgsz + sndcall->addr.len + sndcall->opt.len, in t_kconnect() 108 creq->DEST_length = (t_scalar_t)sndcall->addr.len; in t_kconnect() 109 creq->OPT_length = (t_scalar_t)sndcall->opt.len; in t_kconnect() 111 if (sndcall->addr.len) { in t_kconnect() 112 bcopy(sndcall->addr.buf, (bp->b_wptr+msgsz), sndcall->addr.len); in t_kconnect() 114 msgsz += sndcall->addr.len; in t_kconnect() 118 if (sndcall->opt.len) { in t_kconnect() 119 bcopy(sndcall->opt.buf, (bp->b_wptr+msgsz), sndcall->opt.len); in t_kconnect() [all …]
|
/titanic_41/usr/src/cmd/sendmail/libsm/ |
H A D | fget.c | 53 register int len; variable 66 if ((len = fp->f_r) <= 0) 81 len = fp->f_r; 92 if (len > n) 93 len = n; 94 t = (unsigned char *) memchr((void *) p, '\n', len); 97 len = ++t - p; 98 fp->f_r -= len; 100 (void) memcpy((void *) s, (void *) p, len); 101 s[len] = 0; [all …]
|