aboutsummaryrefslogtreecommitdiff
path: root/lib/libutil/login_crypt.c
diff options
context:
space:
mode:
authorBrian Feldman <green@FreeBSD.org>2000-10-27 01:19:02 +0000
committerBrian Feldman <green@FreeBSD.org>2000-10-27 01:19:02 +0000
commitaa8645587548066172f5222d842444f198ec5613 (patch)
tree7910c5d9f59e7c0e6405689dc2a80cf41939eba5 /lib/libutil/login_crypt.c
parent0a46b1dcccb2a33b9c29a92754f207d05a2174d1 (diff)
downloadsrc-aa8645587548066172f5222d842444f198ec5613.tar.gz
src-aa8645587548066172f5222d842444f198ec5613.zip
Notes
Diffstat (limited to 'lib/libutil/login_crypt.c')
-rw-r--r--lib/libutil/login_crypt.c13
1 files changed, 6 insertions, 7 deletions
diff --git a/lib/libutil/login_crypt.c b/lib/libutil/login_crypt.c
index b291100e335d..e080ba9f28e2 100644
--- a/lib/libutil/login_crypt.c
+++ b/lib/libutil/login_crypt.c
@@ -29,19 +29,18 @@
#include <sys/types.h>
#include <login_cap.h>
+#include <stdio.h>
+#include <stdlib.h>
#include <unistd.h>
-#pragma weak crypt_set_format
-int
-crypt_set_format(const char *f) {
- return (0);
-}
-
const char *
login_setcryptfmt(login_cap_t *lc, const char *def, const char *error) {
const char *cipher;
- cipher = login_getcapstr(lc, "passwd_format", def, NULL);
+ cipher = login_getcapstr(lc, "passwd_format", (char *)def, NULL);
+ if (getenv("CRYPT_DEBUG") != NULL)
+ fprintf(stderr, "login_setcryptfmt: "
+ "passwd_format = %s\n", cipher);
if (cipher == NULL)
return (error);
if (!crypt_set_format(cipher))