Merge branch 'each-style-tweak' into 'master'

adjust clang-format options to get closer to ISC style

See merge request isc-projects/bind9!3061

(cherry picked from commit d3b49b6675)

0255a974 revise .clang-format and add a C formatting script in util
e851ed0b apply the modified style
This commit is contained in:
Ondřej Surý
2020-02-14 05:35:17 +00:00
parent c646c20e79
commit cdef20bb66
672 changed files with 36044 additions and 42228 deletions

View File

@@ -22,13 +22,12 @@
#define USAGE "usage: gencheck <filename>\n"
static int
check(const char *buf, ssize_t count, size_t *start)
{
check(const char *buf, ssize_t count, size_t *start) {
const char chars[] = "abcdefghijklmnopqrstuvwxyz0123456789";
ssize_t i;
ssize_t i;
for (i = 0; i < count;
i++, *start = (*start + 1) % (sizeof(chars) - 1)) {
for (i = 0; i < count; i++, *start = (*start + 1) % (sizeof(chars) - 1))
{
/* Just ignore the trailing newline */
if (buf[i] == '\n') {
continue;
@@ -42,14 +41,13 @@ check(const char *buf, ssize_t count, size_t *start)
}
int
main(int argc, char **argv)
{
int ret;
int fd;
main(int argc, char **argv) {
int ret;
int fd;
ssize_t count;
char buf[1024];
size_t start;
size_t length;
char buf[1024];
size_t start;
size_t length;
ret = EXIT_FAILURE;
fd = -1;