Re: [netatalk-admins] Compiling poppassd under RedHat 4.2/5.0


Subject: Re: [netatalk-admins] Compiling poppassd under RedHat 4.2/5.0
From: Bill Studenmund (skippy@macro.stanford.edu)
Date: Wed Jan 28 1998 - 16:57:22 EST


On Wed, 28 Jan 1998, Carl Beaudry wrote:

> Has anyone here successfully compiled poppassd under either of the last
> two Redhat releases (either with or without shadow passwords.)
>
> I'm still getting the following error:
>
> poppassd.c: In function `chkPass':
> poppassd.c:803: warning: passing arg 1 of `strcmp' makes
> pointer from integer without a cast

This says that the first parameter _to_ strcmp has a problem. I.e. crypt's
not defined right.

> cc -o poppassd poppassd.o
> poppassd.o: In function `chkPass':
> poppassd.o(.text+0xa1b): undefined reference to `crypt'

This error also says crypt's not working right.

> make: *** [poppassd] Error 1
>
> which seems to be coming from the following function:
>
> int chkPass (char *user, char *pass, struct passwd *pw)
> {
> /* Compare the supplied password with the password file entry
> */
> if (strcmp (crypt (pass, pw->pw_passwd), pw->pw_passwd) != 0)
> return (FAILURE);
> else
> return (SUCCESS);
> }
>
> Now it looks to me like strcmp is retuning an integer, which is as it
> should be. Am I missing something obvious here?

Is there a correct prototype to crypt?

I'm not sure how to fix this under Linux.. Sorry.

Take care,

Bill



This archive was generated by hypermail 2b28 : Sat Dec 18 1999 - 16:30:37 EST