diff -ruN courier-authlib-0.59.3-factory/authvchkpw.c courier-authlib-0.59.3-patched/authvchkpw.c --- courier-authlib-0.59.3-factory/authvchkpw.c 2007-04-22 14:53:30.000000000 -0400 +++ courier-authlib-0.59.3-patched/authvchkpw.c 2007-09-14 05:03:22.000000000 -0400 @@ -78,26 +78,6 @@ } #endif -int auth_vchkpw(const char *service, const char *authtype, char *authdata, - int (*callback_func)(struct authinfo *, void *), - void *callback_arg) -{ - if (strcmp(authtype, AUTHTYPE_LOGIN) == 0) - return (auth_vchkpw_login(service, authdata, - callback_func, callback_arg)); - -#if HAVE_HMACLIB - return (auth_vchkpw_cram(service, authtype, authdata, - callback_func, callback_arg)); -#else - errno=EPERM; - return (-1); -#endif - -} - - - static int auth_vchkpw_login(const char *service, char *authdata, int (*callback_func)(struct authinfo *, void *), void *callback_arg) { @@ -163,6 +143,24 @@ return 0; } +int auth_vchkpw(const char *service, const char *authtype, char *authdata, + int (*callback_func)(struct authinfo *, void *), + void *callback_arg) +{ + if (strcmp(authtype, AUTHTYPE_LOGIN) == 0) + return (auth_vchkpw_login(service, authdata, + callback_func, callback_arg)); + +#if HAVE_HMACLIB + return (auth_vchkpw_cram(service, authtype, authdata, + callback_func, callback_arg)); +#else + errno=EPERM; + return (-1); +#endif + +} + static void authvchkpwclose() { } diff -ruN courier-authlib-0.59.3-factory/courier-authlib.spec courier-authlib-0.59.3-patched/courier-authlib.spec --- courier-authlib-0.59.3-factory/courier-authlib.spec 2007-04-22 14:38:08.000000000 -0400 +++ courier-authlib-0.59.3-patched/courier-authlib.spec 2007-09-14 05:04:02.000000000 -0400 @@ -22,6 +22,7 @@ ################################################################################ Source: http://dl.sourceforge.net/courier/%{name}-%{version}.tar.bz2 +Patch0: courier-authlib-0.59.3-auth_vchkpw_login.patch BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) @@ -134,6 +135,7 @@ %prep %setup -q +%patch -p1 %configure --with-redhat %build