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,9 +22,8 @@
isc_mem_t *mctx = NULL;
static void
my_callback(isc_task_t *task, isc_event_t *event)
{
int i, j;
my_callback(isc_task_t *task, isc_event_t *event) {
int i, j;
char *name = event->ev_arg;
j = 0;
@@ -36,8 +35,7 @@ my_callback(isc_task_t *task, isc_event_t *event)
}
static void
my_shutdown(isc_task_t *task, isc_event_t *event)
{
my_shutdown(isc_task_t *task, isc_event_t *event) {
char *name = event->ev_arg;
printf("shutdown %s (%p)\n", name, task);
@@ -45,8 +43,7 @@ my_shutdown(isc_task_t *task, isc_event_t *event)
}
static void
my_tick(isc_task_t *task, isc_event_t *event)
{
my_tick(isc_task_t *task, isc_event_t *event) {
char *name = event->ev_arg;
printf("task %p tick %s\n", task, name);
@@ -61,15 +58,14 @@ static char foo[] = "foo";
static char bar[] = "bar";
int
main(int argc, char *argv[])
{
isc_taskmgr_t * manager = NULL;
isc_task_t * t1 = NULL, *t2 = NULL;
isc_task_t * t3 = NULL, *t4 = NULL;
isc_event_t * event;
unsigned int workers;
isc_timermgr_t * timgr;
isc_timer_t * ti1, *ti2;
main(int argc, char *argv[]) {
isc_taskmgr_t *manager = NULL;
isc_task_t *t1 = NULL, *t2 = NULL;
isc_task_t *t3 = NULL, *t4 = NULL;
isc_event_t *event;
unsigned int workers;
isc_timermgr_t *timgr;
isc_timer_t *ti1, *ti2;
struct isc_interval interval;
if (argc > 1) {