]> The Tcpdump Group git mirrors - tcpdump/commitdiff
Put "{" at end of line with "else" to keep a consistent style
authorFrancois-Xavier Le Bail <[email protected]>
Fri, 21 Apr 2023 12:24:23 +0000 (14:24 +0200)
committerFrancois-Xavier Le Bail <[email protected]>
Fri, 21 Apr 2023 12:56:29 +0000 (14:56 +0200)
(cherry picked from commit 2e99bc485ab304df2d4c797af9576ad1b167c0f8)

[skip ci]

print-frag6.c
print-olsr.c
print-radius.c

index 16e8a4b21926b993f7e1c811dd2ff477695dae87..0ac2fd7f4430d8bd966a6410ce33b8b3c380b653 100644 (file)
@@ -58,8 +58,7 @@ frag6_print(netdissect_options *ndo, const u_char *bp, const u_char *bp2)
        /* it is meaningless to decode non-first fragment */
        if ((GET_BE_U_2(dp->ip6f_offlg) & IP6F_OFF_MASK) != 0)
                return -1;
-       else
-       {
+       else {
                ND_PRINT(" ");
                return sizeof(struct ip6_frag);
        }
index 0ab54f1e2b46044235037056ba883fde54fef642..ecf7918d3647c227bd5d1d2c7605561aafa436fa 100644 (file)
@@ -391,8 +391,7 @@ olsr_print(netdissect_options *ndo,
             msg_tlen = msg_len - sizeof(struct olsr_msg6);
             msg_data = tptr + sizeof(struct olsr_msg6);
         }
-        else /* (!is_ipv6) */
-        {
+        else { /* (!is_ipv6) */
             ND_TCHECK_LEN(tptr, sizeof(struct olsr_msg4));
             msgptr.v4 = (const struct olsr_msg4 *) tptr;
             msg_type = GET_U_1(msgptr.v4->msg_type);
@@ -554,8 +553,7 @@ olsr_print(netdissect_options *ndo,
                     msg_tlen -= sizeof(struct olsr_hna6);
                 }
             }
-            else
-            {
+            else {
                 int col = 0;
 
                 ND_PRINT("\n\t  Advertised networks (total %u)",
index bdbab16c2724c9aec079635f1a7f8541593f6ed3..a8a3ddda2f170331422c957a6fcfa51cc3efe620 100644 (file)
@@ -917,8 +917,7 @@ print_attr_num(netdissect_options *ndo,
          data++;
          data_value = GET_BE_U_3(data);
       }
-      else
-      {
+      else {
          data_value = GET_BE_U_4(data);
       }
       if ( data_value <= (uint32_t)(attr_type[attr_code].siz_subtypes - 1 +
@@ -928,8 +927,7 @@ print_attr_num(netdissect_options *ndo,
       else
          ND_PRINT("#%u", data_value);
    }
-   else
-   {
+   else {
       switch(attr_code) /* Be aware of special cases... */
       {
         case FRM_IPX:
@@ -947,8 +945,7 @@ print_attr_num(netdissect_options *ndo,
              timeout = GET_BE_U_4(data);
              if ( timeout < 60 )
                 ND_PRINT("%02d secs", timeout);
-             else
-             {
+             else {
                 if ( timeout < 3600 )
                    ND_PRINT("%02d:%02d min",
                           timeout / 60, timeout % 60);