[28552] in Kerberos

home help back first fref pref prev next nref lref last post

wrong error checking in kprop.c (bug?)

daemon@ATHENA.MIT.EDU (Ludek Finstrle)
Tue Oct 9 11:46:58 2007

Date: Tue, 9 Oct 2007 09:38:29 +0200
From: Ludek Finstrle <ludek.finstrle@pzkagis.cz>
To: kerberos@mit.edu
Message-ID: <20071009073829.GA9022@pzkagis.cz>
Mime-Version: 1.0
Content-Disposition: inline
Content-Type: text/plain; charset="us-ascii"
Content-Transfer-Encoding: 7bit
Errors-To: kerberos-bounces@mit.edu

Hello,

  suddenly I get "database locked" from kprop since there is no lock
on the dump (even strace show fcntl returns 0 - success).
I found the problem in src/slave/krpop.c. There are these lines:

err = krb5_lock_file(context, fd,
    KRB5_LOCKMODE_SHARED|KRB5_LOCKMODE_DONTBLOCK);
if (err == EAGAIN || err == EWOULDBLOCK || errno == EACCES) {
    com_err(progname, 0, "database locked");
    exit(1);
} else if (err) {
    com_err(progname, err, "while trying to lock '%s'", dbpathname);
    exit(1);
}	    

There is errno instead of err in the if statement. I see the same
problem in ftp://athena-dist.mit.edu/pub/kerberos/dist/vaporware-r-us/krb5-1.6-current.tar.gz too.

Please could someone fix the problem? I'm unable to use krb5-send-pr
due to problems.

If you want more information, please contact me directly as I'm not list
member.

Thanks,

Ludek Finstrle

P.S. I'm going to trace down why krb5_init_context returns 0 and set
  errno to EACCESS.
________________________________________________
Kerberos mailing list           Kerberos@mit.edu
https://mailman.mit.edu/mailman/listinfo/kerberos

home help back first fref pref prev next nref lref last post