aboutsummaryrefslogtreecommitdiffstats
path: root/extras/libmemif/src
diff options
context:
space:
mode:
authorDaniel Béreš <dberes@cisco.com>2023-01-19 10:19:27 +0100
committerDave Wallace <dwallacelf@gmail.com>2024-01-12 03:21:41 +0000
commit985334219458c57b569fdbafcfc6b0d117cc48cf (patch)
tree03260d88a35e0af1142becca3409b011c8d9132d /extras/libmemif/src
parent56e17cf7a23831b353bc1836def47dad7f869dad (diff)
libmemif: added tests
This patch provides unit tests for libmemif written in Unity Type: test Signed-off-by: Daniel Béreš <dberes@cisco.com> Signed-off-by: Mohsin Kazmi <sykazmi@cisco.com> Change-Id: I19116def6e6d28efd5f460c93911245474a11321
Diffstat (limited to 'extras/libmemif/src')
-rw-r--r--extras/libmemif/src/main.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/extras/libmemif/src/main.c b/extras/libmemif/src/main.c
index e735ee35fb1..e87d4c58859 100644
--- a/extras/libmemif/src/main.c
+++ b/extras/libmemif/src/main.c
@@ -412,11 +412,12 @@ memif_connect_handler (memif_fd_event_type_t type, void *private_ctx)
if (ms->timer_fd >= 0)
{
uint64_t u64;
+ ssize_t __attribute__ ((unused)) r;
/*
Have to read the timer fd else it stays read-ready
and makes epoll_pwait() return without sleeping
*/
- read (ms->timer_fd, &u64, sizeof (u64));
+ r = read (ms->timer_fd, &u64, sizeof (u64));
}
/* loop ms->slave_interfaces and request connection for disconnected ones */