mirror of
https://github.com/zeek/zeek.git
synced 2025-10-06 00:28:21 +00:00
Bump clang-format pre-commit hooks
This brings in slightly better formatting around uniform initialization, and comments after blocks not surrounded by `{ .. }`.
This commit is contained in:
parent
0ebcd9608f
commit
97c0df29d4
5 changed files with 9 additions and 10 deletions
|
@ -3,7 +3,7 @@
|
||||||
#
|
#
|
||||||
repos:
|
repos:
|
||||||
- repo: https://github.com/pre-commit/mirrors-clang-format
|
- repo: https://github.com/pre-commit/mirrors-clang-format
|
||||||
rev: 'v18.1.8'
|
rev: 'v19.1.4'
|
||||||
hooks:
|
hooks:
|
||||||
- id: clang-format
|
- id: clang-format
|
||||||
types_or:
|
types_or:
|
||||||
|
|
|
@ -318,7 +318,7 @@ static void addrinfo_cb(void* arg, int status, int timeouts, struct ares_addrinf
|
||||||
// Push a null on the end so the addr list has a final point during later parsing.
|
// Push a null on the end so the addr list has a final point during later parsing.
|
||||||
addrs.push_back(NULL);
|
addrs.push_back(NULL);
|
||||||
|
|
||||||
struct hostent he {};
|
struct hostent he{};
|
||||||
he.h_name = util::copy_string(result->name);
|
he.h_name = util::copy_string(result->name);
|
||||||
he.h_addrtype = AF_INET;
|
he.h_addrtype = AF_INET;
|
||||||
he.h_length = sizeof(in_addr);
|
he.h_length = sizeof(in_addr);
|
||||||
|
@ -333,7 +333,7 @@ static void addrinfo_cb(void* arg, int status, int timeouts, struct ares_addrinf
|
||||||
// Push a null on the end so the addr list has a final point during later parsing.
|
// Push a null on the end so the addr list has a final point during later parsing.
|
||||||
addrs6.push_back(NULL);
|
addrs6.push_back(NULL);
|
||||||
|
|
||||||
struct hostent he {};
|
struct hostent he{};
|
||||||
he.h_name = util::copy_string(result->name);
|
he.h_name = util::copy_string(result->name);
|
||||||
he.h_addrtype = AF_INET6;
|
he.h_addrtype = AF_INET6;
|
||||||
he.h_length = sizeof(in6_addr);
|
he.h_length = sizeof(in6_addr);
|
||||||
|
@ -370,7 +370,7 @@ static void query_cb(void* arg, ares_status_t status, size_t timeouts, const are
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
struct hostent he {};
|
struct hostent he{};
|
||||||
|
|
||||||
uint32_t ttl = 0;
|
uint32_t ttl = 0;
|
||||||
size_t rr_cnt = ares_dns_record_rr_cnt(dnsrec, ARES_SECTION_ANSWER);
|
size_t rr_cnt = ares_dns_record_rr_cnt(dnsrec, ARES_SECTION_ANSWER);
|
||||||
|
|
|
@ -82,8 +82,7 @@ static VectorTypePtr base_vector_type__CPP(const VectorTypePtr& vt, bool is_bool
|
||||||
// Instantiates a double_kernel for a given operation.
|
// Instantiates a double_kernel for a given operation.
|
||||||
#define VEC_OP1_WITH_DOUBLE(name, op) \
|
#define VEC_OP1_WITH_DOUBLE(name, op) \
|
||||||
VEC_OP1( \
|
VEC_OP1( \
|
||||||
name, op, case TYPE_INTERNAL_DOUBLE \
|
name, op, case TYPE_INTERNAL_DOUBLE : { \
|
||||||
: { \
|
|
||||||
VEC_OP1_KERNEL(AsDouble, DoubleVal, op) \
|
VEC_OP1_KERNEL(AsDouble, DoubleVal, op) \
|
||||||
break; \
|
break; \
|
||||||
})
|
})
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue