Re-run clang-format with InsertBraces.
This CL runs the same command as in the preceding CL, but with
'IncludeBraces: true' added to .clang-format. I've split this out
separately because the documentation says:
> Setting this option to true could lead to incorrect code formatting
> due to clang-format’s lack of complete semantic information. As such,
> extra care should be taken to review code changes made by this option.
I've also kept InsertBraces out of .clang-format for now because it's a
fairly recent option, and clang-format fails when it sees unrecognized
options.
Change-Id: I305ea7bb2633704053a1f8de1e11b037b9fc8a76
Reviewed-on: https://boringssl-review.googlesource.com/c/boringssl/+/53086
Commit-Queue: Bob Beck <bbe@google.com>
Reviewed-by: Bob Beck <bbe@google.com>
diff --git a/crypto/asn1/a_mbstr.c b/crypto/asn1/a_mbstr.c
index 2a5ba4b..fd5562c 100644
--- a/crypto/asn1/a_mbstr.c
+++ b/crypto/asn1/a_mbstr.c
@@ -92,10 +92,12 @@
ASN1_STRING *dest;
size_t nchar = 0;
char strbuf[32];
- if (len == -1)
+ if (len == -1) {
len = strlen((const char *)in);
- if (!mask)
+ }
+ if (!mask) {
mask = DIRSTRING_TYPE;
+ }
int (*decode_func)(CBS *, uint32_t *);
int error;
@@ -213,8 +215,9 @@
return -1;
}
- if (!out)
+ if (!out) {
return str_type;
+ }
if (*out) {
free_out = 0;
dest = *out;
@@ -271,8 +274,9 @@
return str_type;
err:
- if (free_out)
+ if (free_out) {
ASN1_STRING_free(dest);
+ }
CBB_cleanup(&cbb);
return -1;
}