From 9f9a554afa4c23284ee624e901e5841ab6636f0d Mon Sep 17 00:00:00 2001 From: Mattias Andrée Date: Tue, 24 Oct 2017 17:34:31 +0200 Subject: Use / instead of . This is more like file path and allows inclusion of package names (and file paths too if you want that for some reason) in the routing key. --- test.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'test.c') diff --git a/test.c b/test.c index 43864b8..c2ba2a8 100644 --- a/test.c +++ b/test.c @@ -258,17 +258,17 @@ check(int fd) size_t i; alarm(1); - assert(!libsbus_subscribe(fd, "test.", 0, buf)); + assert(!libsbus_subscribe(fd, "test/", 0, buf)); assert(!libsbus_subscribe(fd, "discard", 0, buf)); assert(!libsbus_unsubscribe(fd, "discard", 0, buf)); assert(!libsbus_publish(fd, "discard", "not caught", strlen("not caught"), 0, buf)); for (i = 0; i < 100; i++) { - sprintf(key, "test.%zu", i); + sprintf(key, "test/%zu", i); sprintf(msg, "%zu", i); assert(!libsbus_publish(fd, key, msg, strlen(msg), 0, buf)); } for (i = 0; i < 100; i++) { - sprintf(key, "test.%zu", i); + sprintf(key, "test/%zu", i); sprintf(msg, "%zu", i); assert(!libsbus_receive(fd, 0, buf, &packet)); assert(packet.type == LIBSBUS_MESSAGE); -- cgit v1.2.3-70-g09d2