---- 1.3.26 2005/05/04
+--- 1.3.26 2005/05/XX
+
+Configure enables the use the crypt API - if available.
Fixed bug #304: Fuzzy search regExpr-2 did not use proper error distance
of 1.
dnl Zebra, Index Data Aps, 1995-2005
-dnl $Id: configure.in,v 1.91.2.10 2005-05-04 11:48:13 adam Exp $
+dnl $Id: configure.in,v 1.91.2.11 2005-05-12 08:02:47 adam Exp $
dnl
AC_INIT(include/zebraver.h)
AM_INIT_AUTOMAKE(idzebra,1.3.26)
dnl ------ times
AC_CHECK_HEADERS(sys/times.h)
dnl
+dnl ------ crypt
+AC_CHECK_LIB(crypt, crypt)
+if test "$ac_cv_lib_crypt_crypt" = "yes"; then
+ AC_CHECK_HEADERS(crypt.h)
+fi
+dnl
dnl ------ mkstemp
AC_CHECK_FUNCS(mkstemp)
dnl
-/* $Id: passwddb.c,v 1.7 2002-08-02 19:26:57 adam Exp $
+/* $Id: passwddb.c,v 1.7.2.1 2005-05-12 08:02:47 adam Exp $
Copyright (C) 1995,1996,1997,1998,1999,2000,2001,2002
Index Data Aps
#include <string.h>
#include <stdio.h>
-#ifndef USE_CRYPT
-#define USE_CRYPT 0
-#endif
-
-#if USE_CRYPT
+#if HAVE_CRYPT_H
#include <crypt.h>
#endif
int passwd_db_auth (Passwd_db db, const char *user, const char *pass)
{
struct passwd_entry *pe;
-#if USE_CRYPT
+#if HAVE_CRYPT_H
char salt[3];
const char *des_try;
#endif
break;
if (!pe)
return -1;
-#if USE_CRYPT
+#if HAVE_CRYPT_H
if (strlen (pe->des) < 3)
return -3;
if (!pass)