Lines Matching refs:bval
110 adutils_getsid(BerValue *bval, adutils_sid_t *sidp)
130 if (bval->bv_len > 8 && bval->bv_val[0] == 0x01 &&
131 bval->bv_len == 1 + 1 + 6 + bval->bv_val[1] * 4) {
132 v = (uchar_t *)bval->bv_val;
357 convert_bval2sid(BerValue *bval, uint32_t *rid)
361 if (adutils_getsid(bval, &sid) < 0)
380 adutils_bv_objsid2sidstr(BerValue *bval, uint32_t *rid)
384 if (bval == NULL)
387 if ((sid = convert_bval2sid(bval, rid)) == NULL)
394 adutils_sid_ber2str(BerValue *bval)
396 return (adutils_bv_objsid2sidstr(bval, NULL));
405 adutils_bv_uint(BerValue *bval, unsigned int *result)
413 if (bval == NULL || bval->bv_val == NULL)
415 if (bval->bv_len >= sizeof (buf))
418 (void) memcpy(buf, bval->bv_val, bval->bv_len);
419 buf[bval->bv_len] = '\0';
434 adutils_bv_str(BerValue *bval)
438 if (bval == NULL || bval->bv_val == NULL)
440 if ((s = malloc(bval->bv_len + 1)) == NULL)
442 (void) snprintf(s, bval->bv_len + 1, "%.*s", bval->bv_len,
443 bval->bv_val);