From 7a98128e053ccd59203757982f7332ed5e4568ea Mon Sep 17 00:00:00 2001 From: dimitri staessens Date: Thu, 12 Oct 2017 18:12:05 +0200 Subject: lib: Re-enable multi-block support Multi-block support was forgotten during the update of the build system. This enables it again and fixes some bugs when it is disabled and larger SDUs are sent. --- src/tools/cbr/cbr_client.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/tools/cbr/cbr_client.c') diff --git a/src/tools/cbr/cbr_client.c b/src/tools/cbr/cbr_client.c index decf6f96..79425ff2 100644 --- a/src/tools/cbr/cbr_client.c +++ b/src/tools/cbr/cbr_client.c @@ -102,7 +102,7 @@ int client_main(char * server, ts_add(&end, &intv, &end); memcpy(buf, &seqnr, sizeof(seqnr)); - if (flow_write(fd, buf, size) == -1) { + if (flow_write(fd, buf, size) < 0) { stop = true; continue; } @@ -120,7 +120,7 @@ int client_main(char * server, } else { /* flood */ while (!stop) { clock_gettime(CLOCK_REALTIME, &end); - if (flow_write(fd, buf, (size_t) size) == -1) { + if (flow_write(fd, buf, (size_t) size) < 0) { stop = true; continue; } -- cgit v1.2.3