summaryrefslogtreecommitdiff
path: root/libexec
diff options
context:
space:
mode:
authorTed Unangst <tedu@cvs.openbsd.org>2016-09-03 11:24:41 +0000
committerTed Unangst <tedu@cvs.openbsd.org>2016-09-03 11:24:41 +0000
commit0ac95311cf2c1cf6aacfff008f9f8d913799fbd4 (patch)
treec081736af0cc2f2d6602af464998970e73e414e4 /libexec
parentb8ada72e23425a4a5f40109e072aa4b969f91ad7 (diff)
set password to return of readpassphrase(), not always the buffer.
Diffstat (limited to 'libexec')
-rw-r--r--libexec/login_passwd/login.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/libexec/login_passwd/login.c b/libexec/login_passwd/login.c
index bb35e6c4c46..9782ae0be5d 100644
--- a/libexec/login_passwd/login.c
+++ b/libexec/login_passwd/login.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: login.c,v 1.15 2016/09/03 10:50:16 gsoares Exp $ */
+/* $OpenBSD: login.c,v 1.16 2016/09/03 11:24:40 tedu Exp $ */
/*-
* Copyright (c) 1995 Berkeley Software Design, Inc. All rights reserved.
@@ -136,8 +136,7 @@ main(int argc, char **argv)
}
case MODE_LOGIN:
- readpassphrase("Password:", pbuf, sizeof(pbuf), RPP_ECHO_OFF);
- password = pbuf;
+ password = readpassphrase("Password:", pbuf, sizeof(pbuf), RPP_ECHO_OFF);
break;
case MODE_CHALLENGE:
fprintf(back, BI_AUTH "\n");