Blob Blame History Raw
autofs-5.1.7 - remove redundant if check

From: Ian Kent <raven@themaw.net>

Coverity: identical code in if condition branches.

Signed-off-by: Ian Kent <raven@themaw.net>
---
 CHANGELOG       |    1 +
 daemon/direct.c |    5 +----
 2 files changed, 2 insertions(+), 4 deletions(-)

--- autofs-5.1.4.orig/CHANGELOG
+++ autofs-5.1.4/CHANGELOG
@@ -51,6 +51,7 @@
 - remove mounts_mutex.
 - remove unused variable from get_exports().
 - add missing free in handle_mounts().
+- remove redundant if check.
 
 xx/xx/2018 autofs-5.1.5
 - fix flag file permission.
--- autofs-5.1.4.orig/daemon/direct.c
+++ autofs-5.1.4/daemon/direct.c
@@ -752,10 +752,7 @@ int mount_autofs_offset(struct autofs_po
 
 	ops->timeout(ap->logopt, ioctlfd, timeout);
 	cache_set_ino_index(me->mc, me->key, st.st_dev, st.st_ino);
-	if (ap->logopt & LOGOPT_DEBUG)
-		notify_mount_result(ap, me->key, timeout, str_offset);
-	else
-		notify_mount_result(ap, me->key, timeout, str_offset);
+	notify_mount_result(ap, me->key, timeout, str_offset);
 	ops->close(ap->logopt, ioctlfd);
 
 	debug(ap->logopt, "mounted trigger %s", me->key);