wrong errori checking in kprop.c (bug?)

John Hascall john at iastate.edu
Wed Nov 28 17:22:38 EST 2007


>   I wrote mail to the kerberos mail list with (I think) a bug in kprop.c
> one month ago and nothing happen. So I try to send the link here.
> I hope someone take a look at the problem or drop me a note.

> http://mailman.mit.edu/pipermail/kerberos/2007-October/012385.html

Where he wrote:
>   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) {
                                             ^^^^^

  I would tend to agree that should be 'err == EACCESS'
  as errno could easily be EACCESS from some previous syscall.

John



More information about the krbdev mailing list