summaryrefslogtreecommitdiff
path: root/user/kscreenlocker/kscreenlocker-5.8.5-stop-using-getpass.patch
diff options
context:
space:
mode:
authorA. Wilcox <AWilcox@Wilcox-Tech.com>2018-03-04 15:05:51 -0600
committerA. Wilcox <AWilcox@Wilcox-Tech.com>2018-03-04 15:05:51 -0600
commitaa78da47b45ff1d7016d79400253a6e45b265ebe (patch)
tree027ff1920d0abf697389303ef04aaaa3d87ff708 /user/kscreenlocker/kscreenlocker-5.8.5-stop-using-getpass.patch
parentcd8822ac3987a2f52dc313081ade2bf631954d92 (diff)
downloadpackages-aa78da47b45ff1d7016d79400253a6e45b265ebe.tar.gz
packages-aa78da47b45ff1d7016d79400253a6e45b265ebe.tar.bz2
packages-aa78da47b45ff1d7016d79400253a6e45b265ebe.tar.xz
packages-aa78da47b45ff1d7016d79400253a6e45b265ebe.zip
user/[Plasma]: bump to 5.12.2
Diffstat (limited to 'user/kscreenlocker/kscreenlocker-5.8.5-stop-using-getpass.patch')
-rw-r--r--user/kscreenlocker/kscreenlocker-5.8.5-stop-using-getpass.patch71
1 files changed, 0 insertions, 71 deletions
diff --git a/user/kscreenlocker/kscreenlocker-5.8.5-stop-using-getpass.patch b/user/kscreenlocker/kscreenlocker-5.8.5-stop-using-getpass.patch
deleted file mode 100644
index f10789f88..000000000
--- a/user/kscreenlocker/kscreenlocker-5.8.5-stop-using-getpass.patch
+++ /dev/null
@@ -1,71 +0,0 @@
---- kscreenlocker-5.8.5/kcheckpass/kcheckpass.c.old 2016-12-27 11:25:36.000000000 +0000
-+++ kscreenlocker-5.8.5/kcheckpass/kcheckpass.c 2017-01-31 04:32:44.858227055 +0000
-@@ -56,6 +56,7 @@
- #include <stdlib.h>
- #include <errno.h>
- #include <time.h>
-+#include <termios.h>
-
- #include <config-kscreenlocker.h>
- #if HAVE_SYS_PRCTL_H
-@@ -75,9 +76,41 @@
- static int havetty, sfd = -1, nullpass;
-
- static char *
-+better_getpass (void)
-+{
-+ char *password = NULL, *nl;
-+ size_t buf_len = 0;
-+ ssize_t pass_len;
-+ struct termios ti;
-+
-+ tcgetattr(STDIN_FILENO, &ti);
-+ ti.c_lflag &= ~ECHO;
-+ tcsetattr(STDIN_FILENO, TCSANOW, &ti);
-+
-+ pass_len = getdelim(&password, &buf_len, '\n', stdin);
-+
-+ if (pass_len < 0) {
-+ free(password);
-+ return NULL;
-+ }
-+
-+ ti.c_lflag |= ECHO;
-+ tcsetattr(STDIN_FILENO, TCSANOW, &ti);
-+
-+ /* Do not include the \n at the end */
-+ nl = strchr(password, '\n');
-+ if (nl) {
-+ *nl = '\0';
-+ }
-+
-+ return password;
-+}
-+
-+
-+static char *
- conv_legacy (ConvRequest what, const char *prompt)
- {
-- char *p, *p2;
-+ char *p2;
- int len;
- char buf[1024];
-
-@@ -99,13 +132,10 @@
- return strdup(buf);
- case ConvGetHidden:
- if (havetty) {
--#ifdef HAVE_GETPASSPHRASE
-- p = getpassphrase(prompt ? prompt : "Password: ");
--#else
-- p = getpass(prompt ? prompt : "Password: ");
--#endif
-- p2 = strdup(p);
-- memset(p, 0, strlen(p));
-+ fputs(prompt ? prompt : "Password: ", stdout);
-+ fflush(stdout);
-+ p2 = better_getpass();
-+ printf("\n");
- return p2;
- } else {
- if (prompt)