summaryrefslogtreecommitdiff
path: root/src/tools
diff options
context:
space:
mode:
authorDimitri Staessens <dimitri@ouroboros.rocks>2021-06-15 14:32:44 +0200
committerSander Vrijders <sander@ouroboros.rocks>2021-06-18 08:44:26 +0200
commit7b13504e2a47a40ae7e5283de41d48ca3f7efb53 (patch)
treeb66b2d6b74117eee3dc5977f925fef4feea210c8 /src/tools
parent19aa8f61863234556d00094e1ecf9fd645a41cb6 (diff)
downloadouroboros-7b13504e2a47a40ae7e5283de41d48ca3f7efb53.tar.gz
ouroboros-7b13504e2a47a40ae7e5283de41d48ca3f7efb53.zip
tools: Support broadcast IPCP in irm ipcp list
The broadcast IPCP was missing in the known types, causing the type to show as UNKNOWN. Signed-off-by: Dimitri Staessens <dimitri@ouroboros.rocks> Signed-off-by: Sander Vrijders <sander@ouroboros.rocks>
Diffstat (limited to 'src/tools')
-rw-r--r--src/tools/irm/irm_ipcp_list.c15
1 files changed, 10 insertions, 5 deletions
diff --git a/src/tools/irm/irm_ipcp_list.c b/src/tools/irm/irm_ipcp_list.c
index 9def49d5..512e1645 100644
--- a/src/tools/irm/irm_ipcp_list.c
+++ b/src/tools/irm/irm_ipcp_list.c
@@ -46,11 +46,12 @@
#include <stdlib.h>
#include <string.h>
-#define UNICAST "unicast"
-#define UDP "udp"
-#define ETH_LLC "eth-llc"
-#define ETH_DIX "eth-dix"
-#define LOCAL "local"
+#define UNICAST "unicast"
+#define BROADCAST "broadcast"
+#define UDP "udp"
+#define ETH_LLC "eth-llc"
+#define ETH_DIX "eth-dix"
+#define LOCAL "local"
static void usage(void)
{
@@ -67,6 +68,8 @@ static char * str_type(enum ipcp_type type)
switch(type) {
case IPCP_UNICAST:
return UNICAST;
+ case IPCP_BROADCAST:
+ return BROADCAST;
case IPCP_ETH_LLC:
return ETH_LLC;
case IPCP_ETH_DIX:
@@ -108,6 +111,8 @@ int do_list_ipcp(int argc,
if (ipcp_type != NULL) {
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)
type = IPCP_UDP;
else if (strcmp(ipcp_type, LOCAL) == 0)