diff options
| author | Dimitri Staessens <dimitri@ouroboros.rocks> | 2019-07-25 12:50:46 +0200 | 
|---|---|---|
| committer | Sander Vrijders <sander@ouroboros.rocks> | 2019-07-29 19:36:45 +0200 | 
| commit | dae15c284248d49079ad5f8a3d8ff30e217f419e (patch) | |
| tree | ea7942e940396c0c78304fef8b43fb25c5aebba8 /src/tools/irm | |
| parent | c9232acef855b51d1bc199a68c03c0695ac11192 (diff) | |
| download | ouroboros-dae15c284248d49079ad5f8a3d8ff30e217f419e.tar.gz ouroboros-dae15c284248d49079ad5f8a3d8ff30e217f419e.zip | |
build: Refactor normal to unicast
This completes the renaming of the normal IPCP to the unicast IPCP in
the sources, to get everything consistent with the documentation.
Signed-off-by: Dimitri Staessens <dimitri@ouroboros.rocks>
Signed-off-by: Sander Vrijders <sander@ouroboros.rocks>
Diffstat (limited to 'src/tools/irm')
| -rw-r--r-- | src/tools/irm/irm_ipcp_bootstrap.c | 14 | ||||
| -rw-r--r-- | src/tools/irm/irm_ipcp_connect.c | 2 | ||||
| -rw-r--r-- | src/tools/irm/irm_ipcp_create.c | 8 | ||||
| -rw-r--r-- | src/tools/irm/irm_ipcp_disconnect.c | 2 | ||||
| -rw-r--r-- | src/tools/irm/irm_ipcp_enroll.c | 12 | ||||
| -rw-r--r-- | src/tools/irm/irm_ipcp_list.c | 12 | 
6 files changed, 25 insertions, 25 deletions
| diff --git a/src/tools/irm/irm_ipcp_bootstrap.c b/src/tools/irm/irm_ipcp_bootstrap.c index 7134bf64..fae9a413 100644 --- a/src/tools/irm/irm_ipcp_bootstrap.c +++ b/src/tools/irm/irm_ipcp_bootstrap.c @@ -50,7 +50,7 @@  #include <sys/socket.h>  #endif -#define NORMAL                 "unicast" +#define UNICAST                 "unicast"  #define BROADCAST              "broadcast"  #define UDP                    "udp"  #define ETH_LLC                "eth-llc" @@ -89,9 +89,9 @@ static void usage(void)                 "                name <ipcp name>\n"                 "                layer <layer name>\n"                 "                [type [TYPE]]\n" -               "where TYPE = {" NORMAL " " BROADCAST " " LOCAL " " +               "where TYPE = {" UNICAST " " BROADCAST " " LOCAL " "                 UDP " " ETH_LLC " " ETH_DIX " " RAPTOR "},\n\n" -               "if TYPE == " NORMAL "\n" +               "if TYPE == " UNICAST "\n"                 "                [addr <address size> (default: %d)]\n"                 "                [eid <eid size> (default: %d)]\n"                 "                [ttl (max time-to-live value, default: %d)]\n" @@ -262,8 +262,8 @@ int do_bootstrap_ipcp(int     argc,          }          if (ipcp_type != NULL) { -                if (strcmp(ipcp_type, NORMAL) == 0) -                        type = IPCP_NORMAL; +                if (strcmp(ipcp_type, UNICAST) == 0) +                        type = IPCP_UNICAST;                  else if (strcmp(ipcp_type, BROADCAST) == 0)                          type = IPCP_BROADCAST;                  else if (strcmp(ipcp_type, UDP) == 0) @@ -301,7 +301,7 @@ int do_bootstrap_ipcp(int     argc,                          }                          conf.type = ipcps[i].type; -                        if (autobind && (conf.type != IPCP_NORMAL && +                        if (autobind && (conf.type != IPCP_UNICAST &&                                           conf.type != IPCP_BROADCAST)) {                                  printf("Can not bind this IPCP type,"                                         "autobind disabled.\n\n"); @@ -318,7 +318,7 @@ int do_bootstrap_ipcp(int     argc,                                  conf.layer_info.dir_hash_algo = hash_algo;                          switch (conf.type) { -                        case IPCP_NORMAL: +                        case IPCP_UNICAST:                                  conf.addr_size      = addr_size;                                  conf.eid_size       = eid_size;                                  conf.max_ttl        = max_ttl; diff --git a/src/tools/irm/irm_ipcp_connect.c b/src/tools/irm/irm_ipcp_connect.c index 59d0ace8..6188a14f 100644 --- a/src/tools/irm/irm_ipcp_connect.c +++ b/src/tools/irm/irm_ipcp_connect.c @@ -1,7 +1,7 @@  /*   * Ouroboros - Copyright (C) 2016 - 2019   * - * Connect components of normal IPC Processes + * Connect components of unicast or broadcast IPC processes   *   *    Dimitri Staessens <dimitri.staessens@ugent.be>   *    Sander Vrijders   <sander.vrijders@ugent.be> diff --git a/src/tools/irm/irm_ipcp_create.c b/src/tools/irm/irm_ipcp_create.c index 8ce14104..6812c22a 100644 --- a/src/tools/irm/irm_ipcp_create.c +++ b/src/tools/irm/irm_ipcp_create.c @@ -44,7 +44,7 @@  #include "irm_ops.h"  #include "irm_utils.h" -#define NORMAL                 "unicast" +#define UNICAST                 "unicast"  #define BROADCAST              "broadcast"  #define UDP                    "udp"  #define ETH_LLC                "eth-llc" @@ -57,7 +57,7 @@ static void usage(void)          printf("Usage: irm ipcp create\n"                 "                name <ipcp name>\n"                 "                type [TYPE]\n\n" -               "where TYPE = {" NORMAL " " BROADCAST " " LOCAL " " +               "where TYPE = {" UNICAST " " BROADCAST " " LOCAL " "                 UDP " " ETH_LLC " " RAPTOR "}\n");  } @@ -89,8 +89,8 @@ int do_create_ipcp(int     argc,                  return -1;          } -        if (strcmp(ipcp_type, NORMAL) == 0) -                type = IPCP_NORMAL; +        if (strcmp(ipcp_type, UNICAST) == 0) +                type = IPCP_UNICAST;          else if (strcmp(ipcp_type, BROADCAST) == 0)                  type = IPCP_BROADCAST;          else if (strcmp(ipcp_type, UDP) == 0) diff --git a/src/tools/irm/irm_ipcp_disconnect.c b/src/tools/irm/irm_ipcp_disconnect.c index 67a728af..5674ecfe 100644 --- a/src/tools/irm/irm_ipcp_disconnect.c +++ b/src/tools/irm/irm_ipcp_disconnect.c @@ -1,7 +1,7 @@  /*   * Ouroboros - Copyright (C) 2016 - 2019   * - * Connect components of normal IPC Processes + * Connect components of unicast or broadcast IPC processes   *   *    Dimitri Staessens <dimitri.staessens@ugent.be>   *    Sander Vrijders   <sander.vrijders@ugent.be> diff --git a/src/tools/irm/irm_ipcp_enroll.c b/src/tools/irm/irm_ipcp_enroll.c index 1053683b..5aff790f 100644 --- a/src/tools/irm/irm_ipcp_enroll.c +++ b/src/tools/irm/irm_ipcp_enroll.c @@ -46,7 +46,7 @@  #include <string.h> -#define NORMAL    "unicast" +#define UNICAST    "unicast"  #define BROADCAST "broadcast"  static void usage(void) @@ -55,9 +55,9 @@ static void usage(void)                 "                name <ipcp name>\n"                 "                [layer <layer to enroll with>]\n"                 "                [dst <destination to enroll with>]\n" -               "                [type [TYPE], default = " NORMAL "]\n" +               "                [type [TYPE], default = " UNICAST "]\n"                 "                [autobind]\n" -               "where TYPE = {" NORMAL " " BROADCAST "}\n"); +               "where TYPE = {" UNICAST " " BROADCAST "}\n");  }  static int get_layer_name(const char * ipcp, @@ -92,7 +92,7 @@ int do_enroll_ipcp(int     argc,          int                i         = 0;          bool               autobind  = false;          int                cargs; -        char *             ipcp_type = NORMAL; +        char *             ipcp_type = UNICAST;          enum ipcp_type     type      = IPCP_INVALID;          while (argc > 0) { @@ -126,8 +126,8 @@ int do_enroll_ipcp(int     argc,          if (dst == NULL)                  dst = layer; -        if (strcmp(ipcp_type, NORMAL) == 0) -                type = IPCP_NORMAL; +        if (strcmp(ipcp_type, UNICAST) == 0) +                type = IPCP_UNICAST;          else if (strcmp(ipcp_type, BROADCAST) == 0)                  type = IPCP_BROADCAST; diff --git a/src/tools/irm/irm_ipcp_list.c b/src/tools/irm/irm_ipcp_list.c index 5fd306a9..f2dfa271 100644 --- a/src/tools/irm/irm_ipcp_list.c +++ b/src/tools/irm/irm_ipcp_list.c @@ -46,7 +46,7 @@  #include <stdlib.h>  #include <string.h> -#define NORMAL  "unicast" +#define UNICAST  "unicast"  #define UDP     "udp"  #define ETH_LLC "eth-llc"  #define ETH_DIX "eth-dix" @@ -59,15 +59,15 @@ static void usage(void)                 "                [name  <ipcp name>]\n"                 "                [layer <layer_name>]\n\n"                 "                [type [TYPE]]\n\n" -               "where TYPE = {" NORMAL " " LOCAL " " +               "where TYPE = {" UNICAST " " LOCAL " "                 UDP " " ETH_LLC " " ETH_DIX " " RAPTOR "}\n");  }  static char * str_type(enum ipcp_type type)  {          switch(type) { -        case IPCP_NORMAL: -                return NORMAL; +        case IPCP_UNICAST: +                return UNICAST;          case IPCP_ETH_LLC:                  return ETH_LLC;          case IPCP_ETH_DIX: @@ -109,8 +109,8 @@ int do_list_ipcp(int     argc,          }          if (ipcp_type != NULL) { -                if (strcmp(ipcp_type, NORMAL) == 0) -                        type = IPCP_NORMAL; +                if (strcmp(ipcp_type, UNICAST) == 0) +                        type = IPCP_UNICAST;                  else if (strcmp(ipcp_type, UDP) == 0)                          type = IPCP_UDP;                  else if (strcmp(ipcp_type, LOCAL) == 0) | 
