Skip to content

Commit

Permalink
netrom: Reduce switch/case indent
Browse files Browse the repository at this point in the history
Make the case labels the same indent as the switch.

git diff -w shows code on same line as case moved
to separate lines and a "/* Fallthrough */" comment
added where appropriate.

Signed-off-by: Joe Perches <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
  • Loading branch information
JoePerches authored and davem330 committed Jul 1, 2011
1 parent fcb261f commit c485538
Showing 1 changed file with 13 additions and 9 deletions.
22 changes: 13 additions & 9 deletions net/netrom/nr_route.c
Original file line number Diff line number Diff line change
Expand Up @@ -257,9 +257,12 @@ static int __must_check nr_add_node(ax25_address *nr, const char *mnemonic,
case 3:
if (nr_node->routes[1].quality > nr_node->routes[0].quality) {
switch (nr_node->which) {
case 0: nr_node->which = 1; break;
case 1: nr_node->which = 0; break;
default: break;
case 0:
nr_node->which = 1;
break;
case 1:
nr_node->which = 0;
break;
}
nr_route = nr_node->routes[0];
nr_node->routes[0] = nr_node->routes[1];
Expand Down Expand Up @@ -505,12 +508,13 @@ static int nr_dec_obs(void)
s->count--;

switch (i) {
case 0:
s->routes[0] = s->routes[1];
case 1:
s->routes[1] = s->routes[2];
case 2:
break;
case 0:
s->routes[0] = s->routes[1];
/* Fallthrough */
case 1:
s->routes[1] = s->routes[2];
case 2:
break;
}
break;

Expand Down

0 comments on commit c485538

Please sign in to comment.