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

[dm-devel] waiteventloop loops once more than it needs to



In waitevntloop(), you get the current event_nr, and then wait for an
event. After the event, the event_nr will always be at least one greater.
This means that waiteventloop will always run mark_failed_path() once more
than needed. This patch, against multipath-tools-0.4.4-pre15, fixes that.

-Ben
diff -urN multipath-tools-0.4.4-pre15/multipathd/main.c multipath-tools-waiteventloop-fix/multipathd/main.c
--- multipath-tools-0.4.4-pre15/multipathd/main.c	2005-04-19 10:04:10.000000000 -0500
+++ multipath-tools-waiteventloop-fix/multipathd/main.c	2005-04-19 15:23:05.000000000 -0500
@@ -298,7 +298,7 @@
 	dm_task_no_open_count(dmt);
 
 	dm_task_run(dmt);
-
+	waiter->event_nr++;
 	/*
 	 * upon event ...
 	 */

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