Format preprocessor conditionals
Signed-off-by: Agathiyan Bragadeesh <agathiyan.bragadeesh2@arm.com>
This commit is contained in:
parent
ed88eefe8e
commit
ee642d93a8
2 changed files with 6 additions and 6 deletions
|
@ -871,7 +871,7 @@ int mbedtls_x509_dn_gets(char *buf, size_t size, const mbedtls_x509_name *dn)
|
||||||
MBEDTLS_X509_SAFE_SNPRINTF;
|
MBEDTLS_X509_SAFE_SNPRINTF;
|
||||||
|
|
||||||
if (print_hexstring) {
|
if (print_hexstring) {
|
||||||
#if defined(MBEDTLS_ASN1_WRITE_C)
|
#if defined(MBEDTLS_ASN1_WRITE_C)
|
||||||
s[0] = '#';
|
s[0] = '#';
|
||||||
|
|
||||||
c = name->val.tag;
|
c = name->val.tag;
|
||||||
|
@ -897,9 +897,9 @@ int mbedtls_x509_dn_gets(char *buf, size_t size, const mbedtls_x509_name *dn)
|
||||||
s[j++] = nibble_to_hex_digit(highbits);
|
s[j++] = nibble_to_hex_digit(highbits);
|
||||||
s[j] = nibble_to_hex_digit(lowbits);
|
s[j] = nibble_to_hex_digit(lowbits);
|
||||||
}
|
}
|
||||||
#else
|
#else
|
||||||
return MBEDTLS_ERR_X509_FEATURE_UNAVAILABLE;
|
return MBEDTLS_ERR_X509_FEATURE_UNAVAILABLE;
|
||||||
#endif
|
#endif
|
||||||
} else {
|
} else {
|
||||||
for (i = 0, j = 0; i < name->val.len; i++, j++) {
|
for (i = 0, j = 0; i < name->val.len; i++, j++) {
|
||||||
if (j >= sizeof(s) - 1) {
|
if (j >= sizeof(s) - 1) {
|
||||||
|
|
|
@ -303,15 +303,15 @@ int mbedtls_x509_string_to_names(mbedtls_asn1_named_data **head, const char *nam
|
||||||
tag = attr_descr->default_tag;
|
tag = attr_descr->default_tag;
|
||||||
}
|
}
|
||||||
if (numericoid) {
|
if (numericoid) {
|
||||||
#if defined(MBEDTLS_ASN1_PARSE_C)
|
#if defined(MBEDTLS_ASN1_PARSE_C)
|
||||||
if ((parse_ret =
|
if ((parse_ret =
|
||||||
parse_attribute_value_ber_encoded(s, (int) (c - s), data, &data_len,
|
parse_attribute_value_ber_encoded(s, (int) (c - s), data, &data_len,
|
||||||
&tag)) != 0) {
|
&tag)) != 0) {
|
||||||
return parse_ret;
|
return parse_ret;
|
||||||
}
|
}
|
||||||
#else
|
#else
|
||||||
return MBEDTLS_ERR_X509_INVALID_NAME;
|
return MBEDTLS_ERR_X509_INVALID_NAME;
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
mbedtls_asn1_named_data *cur =
|
mbedtls_asn1_named_data *cur =
|
||||||
mbedtls_asn1_store_named_data(head, oid, strlen(oid),
|
mbedtls_asn1_store_named_data(head, oid, strlen(oid),
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue