From 9dab3985812e75071271ce69000561156d0d9374 Mon Sep 17 00:00:00 2001 From: Dimitri Staessens Date: Thu, 27 Dec 2018 15:42:00 +0100 Subject: include: Add a flow_join operation for broadcast This adds a new flow_join operaiton for broadcast, which is a much safer solution than overloading destination name semantics. The internal API now also has a different IPCP_FLOW_JOIN operation. The IRMd doesn't need to query broadcasts IPCPs for the name, it can just check if an IPCP with the layer name exists. The broadcast IPCP doesn't need to implement the query proxy call anymore. Signed-off-by: Dimitri Staessens Signed-off-by: Sander Vrijders --- src/tools/obc/obc.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'src/tools/obc') diff --git a/src/tools/obc/obc.c b/src/tools/obc/obc.c index 747d01d3..e3fba557 100644 --- a/src/tools/obc/obc.c +++ b/src/tools/obc/obc.c @@ -63,9 +63,9 @@ static int reader_main(const char * dst) printf("Starting a reader.\n"); - fd = flow_alloc(dst, NULL, NULL); + fd = flow_join(dst, NULL, NULL); if (fd < 0) { - printf("Failed to allocate multicast flow.\n"); + printf("Failed to join broadcast.\n"); return -1; } @@ -90,9 +90,9 @@ static int writer_main(const char * dst, { int fd = 0; - fd = flow_alloc(dst, NULL, NULL); + fd = flow_join(dst, NULL, NULL); if (fd < 0) { - printf("Failed to allocate multicast flow.\n"); + printf("Failed to join broadcast.\n"); return -1; } -- cgit v1.2.3