Blame SOURCES/autofs-5.0.7-fix-incorrect-check-in-flag_is_owned.patch

306fa1
autofs-5.0.7 - fix incorrect check in flag_is_owned()
306fa1
306fa1
From: Ian Kent <raven@themaw.net>
306fa1
306fa1
The flag file code isn't used any more but this is clearly incorrect
306fa1
so fix it in case it gets used sometime in the future.
306fa1
---
306fa1
 daemon/flag.c |    7 +++----
306fa1
 1 file changed, 3 insertions(+), 4 deletions(-)
306fa1
306fa1
diff --git a/daemon/flag.c b/daemon/flag.c
306fa1
index f8fe163..db9a4bd 100644
306fa1
--- a/daemon/flag.c
306fa1
+++ b/daemon/flag.c
306fa1
@@ -66,12 +66,11 @@ static int flag_is_owned(int fd)
306fa1
 
306fa1
 			continue;
306fa1
 		}
306fa1
-
306fa1
-		/* Stale flagfile */
306fa1
-		if (!tries)
306fa1
-			return 0;
306fa1
 	}
306fa1
 
306fa1
+	/* Stale flagfile */
306fa1
+	if (!tries)
306fa1
+		return 0;
306fa1
 
306fa1
 	if (pid) {
306fa1
 		int ret;