aboutsummaryrefslogtreecommitdiff
path: root/demo/async/client.c
diff options
context:
space:
mode:
Diffstat (limited to 'demo/async/client.c')
-rw-r--r--demo/async/client.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/demo/async/client.c b/demo/async/client.c
index bf9389a0..18622089 100644
--- a/demo/async/client.c
+++ b/demo/async/client.c
@@ -1,4 +1,4 @@
-// Copyright 2018 Staysail Systems, Inc. <info@staysail.tech>
+// Copyright 2025 Staysail Systems, Inc. <info@staysail.tech>
// Copyright 2018 Capitar IT Group BV <info@capitoar.com>
//
// This software is supplied under the terms of the MIT License, a
@@ -26,7 +26,6 @@
#include <time.h>
#include <nng/nng.h>
-#include <nng/protocol/reqrep0/req.h>
#include <nng/supplemental/util/platform.h>
void
@@ -49,6 +48,10 @@ client(const char *url, const char *msecstr)
msec = atoi(msecstr);
+ if ((rv = nng_init(NULL)) != 0) {
+ fatal("nng_init", rv);
+ }
+
if ((rv = nng_req0_open(&sock)) != 0) {
fatal("nng_req0_open", rv);
}