cdown / rpms / util-linux

Forked from rpms/util-linux 2 years ago
Clone

Blame SOURCES/0165-sulogin-Always-make-echo-work-after-performing-getpa.patch

ad9577
From 6bb8e6d4c38f260109852ef8b43876ea1aff3810 Mon Sep 17 00:00:00 2001
ad9577
From: Werner Fink <werner@suse.de>
ad9577
Date: Tue, 22 Mar 2016 10:38:59 +0100
ad9577
Subject: [PATCH 165/173] sulogin: Always make echo work after performing
ad9577
 getpasswd even if root account is locked
ad9577
ad9577
If the root account is locked and no password was provided then the terminal
ad9577
line is not set back to do echo of the input. This correct a small overlook
ad9577
in commit 7ff1162e67164cb4ece19dd809c26272461aa254
ad9577
ad9577
Upstream: http://github.com/karelzak/util-linux/commit/6988998b66b4b95c494d60599f8e3de2ffbaeece
ad9577
Addresses: http://bugzilla.redhat.com/show_bug.cgi?id=1561200
ad9577
Signed-off-by: Werner Fink <werner@suse.de>
ad9577
---
ad9577
 login-utils/sulogin.c | 3 +--
ad9577
 1 file changed, 1 insertion(+), 2 deletions(-)
ad9577
ad9577
diff --git a/login-utils/sulogin.c b/login-utils/sulogin.c
ad9577
index a17b91d71..a6918282e 100644
ad9577
--- a/login-utils/sulogin.c
ad9577
+++ b/login-utils/sulogin.c
ad9577
@@ -676,8 +676,7 @@ quit:
ad9577
 	alarm(0);
ad9577
 	if (tc)
ad9577
 		tcsetattr(fd, TCSAFLUSH, &con->tio);
ad9577
-	if (ret && *ret != '\0')
ad9577
-		tcfinal(con);
ad9577
+	tcfinal(con);
ad9577
 	printf("\r\n");
ad9577
 out:
ad9577
 	return ret;
ad9577
-- 
ad9577
2.14.4
ad9577