aboutsummaryrefslogtreecommitdiff
path: root/tests/scalability.c
diff options
context:
space:
mode:
authorEdward Rudd <urkle@outoforder.cc>2021-12-29 10:13:09 -0500
committerGitHub <noreply@github.com>2021-12-29 07:13:09 -0800
commit44fadb7042fbfdf75f20572c59e410f406bb82f4 (patch)
treeaa8380a652d7666f9f51732361494db79ec7114a /tests/scalability.c
parent6cf5acb15147766eebdd6cf2731eacd8e0e31518 (diff)
downloadnng-44fadb7042fbfdf75f20572c59e410f406bb82f4.tar.gz
nng-44fadb7042fbfdf75f20572c59e410f406bb82f4.tar.bz2
nng-44fadb7042fbfdf75f20572c59e410f406bb82f4.zip
don't use deprecated functions in tests (#1560)
Diffstat (limited to 'tests/scalability.c')
-rw-r--r--tests/scalability.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/tests/scalability.c b/tests/scalability.c
index 0cff2243..17d6ce70 100644
--- a/tests/scalability.c
+++ b/tests/scalability.c
@@ -53,8 +53,8 @@ openclients(nng_socket *clients, int num)
t = 100; // 100ms
nng_socket c;
if (((rv = nng_req_open(&c)) != 0) ||
- ((rv = nng_setopt_ms(c, NNG_OPT_RECVTIMEO, t)) != 0) ||
- ((rv = nng_setopt_ms(c, NNG_OPT_SENDTIMEO, t)) != 0) ||
+ ((rv = nng_socket_set_ms(c, NNG_OPT_RECVTIMEO, t)) != 0) ||
+ ((rv = nng_socket_set_ms(c, NNG_OPT_SENDTIMEO, t)) != 0) ||
((rv = nng_dial(c, addr, NULL, 0)) != 0)) {
return (rv);
}
@@ -93,8 +93,8 @@ Main({
results = calloc(nclients, sizeof(int));
if ((nng_rep_open(&rep) != 0) ||
- (nng_setopt_int(rep, NNG_OPT_RECVBUF, 256) != 0) ||
- (nng_setopt_int(rep, NNG_OPT_SENDBUF, 256) != 0) ||
+ (nng_socket_set_int(rep, NNG_OPT_RECVBUF, 256) != 0) ||
+ (nng_socket_set_int(rep, NNG_OPT_SENDBUF, 256) != 0) ||
(nng_listen(rep, addr, NULL, 0) != 0) ||
(nng_thread_create(&server, serve, NULL) != 0)) {
fprintf(stderr, "Unable to set up server!\n");