[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

[dm-devel] [PATCH 2/5] multipath-tools: Log all messages



When the log thread pulls the last message off the buffer, it sets
la->empty.  However, then it returns la->empty, which means that the log is
empty, instead of 0, which means that it found a message.  This means that
multipathd is not logging the last message in the buffer when the log threa
runs. This patch changes the return code, so that multipathd logs all the
messages in the buffer.

Signed-off-by: Benjamin Marzinski <bmarzins redhat com>
---
 libmultipath/log.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Index: multipath-tools/libmultipath/log.c
===================================================================
--- multipath-tools.orig/libmultipath/log.c
+++ multipath-tools/libmultipath/log.c
@@ -181,7 +181,7 @@ int log_dequeue (void * buff)
 
 	memset((void *)src, 0,  len);
 
-	return la->empty;
+	return 0;
 }
 
 /*


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]