Blob Blame History Raw
From bd4e73b0da7d5567f7d0d3639a1b72af8190f022 Mon Sep 17 00:00:00 2001
From: "Gao,Yan" <ygao@suse.com>
Date: Thu, 1 Jun 2017 13:42:36 +0200
Subject: [PATCH] Fix: sbd-inquisitor: Correctly look up servant by device name

---
 src/sbd-inquisitor.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/sbd-inquisitor.c b/src/sbd-inquisitor.c
index 30be8b2..cd7d914 100644
--- a/src/sbd-inquisitor.c
+++ b/src/sbd-inquisitor.c
@@ -104,7 +104,7 @@ struct servants_list_item *lookup_servant_by_dev(const char *devname)
 	struct servants_list_item *s;
 
 	for (s = servants_leader; s; s = s->next) {
-		if (strncasecmp(s->devname, devname, strlen(s->devname)))
+		if (strcasecmp(s->devname, devname) == 0)
 			break;
 	}
 	return s;
-- 
1.8.3.1