summaryrefslogtreecommitdiff
path: root/src/lib
diff options
context:
space:
mode:
Diffstat (limited to 'src/lib')
-rw-r--r--src/lib/CMakeLists.txt2
-rw-r--r--src/lib/config.h.in1
-rw-r--r--src/lib/dev.c2
3 files changed, 5 insertions, 0 deletions
diff --git a/src/lib/CMakeLists.txt b/src/lib/CMakeLists.txt
index c1b8f354..ba670acf 100644
--- a/src/lib/CMakeLists.txt
+++ b/src/lib/CMakeLists.txt
@@ -165,6 +165,8 @@ set(SHM_RDRB_NAME "/${SHM_PREFIX}.rdrb" CACHE INTERNAL
"Name for the main POSIX shared memory buffer")
set(SHM_RDRB_BLOCK_SIZE "sysconf(_SC_PAGESIZE)" CACHE STRING
"SDU buffer block size, multiple of pagesize for performance")
+set(SHM_RDRB_MULTI_BLOCK true CACHE BOOL
+ "SDU buffer multiblock SDU support")
set(SHM_RBUFF_LOCKLESS 0 CACHE BOOL
"Enable shared memory lockless rbuff support")
diff --git a/src/lib/config.h.in b/src/lib/config.h.in
index a85ce7b4..40ac945d 100644
--- a/src/lib/config.h.in
+++ b/src/lib/config.h.in
@@ -27,6 +27,7 @@
#define SYS_MAX_FLOWS @SYS_MAX_FLOWS@
#cmakedefine SHM_RBUFF_LOCKLESS
+#cmakedefine SHM_RDRB_MULTI_BLOCK
#define SHM_RBUFF_PREFIX "@SHM_RBUFF_PREFIX@"
#define SHM_LOCKFILE_NAME "@SHM_LOCKFILE_NAME@"
diff --git a/src/lib/dev.c b/src/lib/dev.c
index 99d3ecec..85dbfb0a 100644
--- a/src/lib/dev.c
+++ b/src/lib/dev.c
@@ -1098,6 +1098,8 @@ ssize_t flow_write(int fd,
DU_BUFF_TAILSPACE,
buf,
count);
+ if (idx < 0)
+ return idx;
pthread_rwlock_rdlock(&ai.lock);
}