From a8db9df8b37e7fba2f84b36b3167fbf02d03d039 Mon Sep 17 00:00:00 2001 From: msweet Date: Mon, 4 Jan 2016 14:34:55 +0000 Subject: [PATCH] The default password function did not work on some platforms (STR #4750) git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/trunk@13029 a1ca3aef-8c08-0410-bb20-df032aa958be --- CHANGES-2.1.txt | 2 ++ cups/usersys.c | 4 +++- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/CHANGES-2.1.txt b/CHANGES-2.1.txt index 6a0107e378..51c784e725 100644 --- a/CHANGES-2.1.txt +++ b/CHANGES-2.1.txt @@ -3,6 +3,8 @@ CHANGES-2.1.txt CHANGES IN CUPS V2.1.3 + - The default password function did not work on some platforms + (STR #4750) - The scheduler should not exit under memory pressure () - The EPL2 and ZPL sample drivers did not properly support the CutMedia diff --git a/cups/usersys.c b/cups/usersys.c index acf82db59f..9b3c219b7e 100644 --- a/cups/usersys.c +++ b/cups/usersys.c @@ -710,6 +710,8 @@ _cupsGetPassword(const char *prompt) /* I - Prompt string */ noecho = original; noecho.c_lflag &= (tcflag_t)~(ICANON | ECHO | ECHOE | ISIG); + noecho.c_cc[VMIN] = 1; + noecho.c_cc[VTIME] = 0; if (tcsetattr(tty, TCSAFLUSH, &noecho)) { @@ -1234,7 +1236,7 @@ cups_set_ssl_options( for (start = temp; *start; start = end) { - /* + /* * Find end of keyword... */ -- 2.47.2