[Raw Msg Headers][Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

fix for Linux locks at ZMailer 2.99.36



Well, I begun to wonder, why my mailbox had prolonged delivery queue
(2h30min), and then I remembered that new Linuxes don't like simultaneous
use of incompatible locking styles.  Namely  lockf()  and  flock()   must
not be used at the same execution of a program.

Also I noticed something mighty strange at  libc/whathost.c,  but perhaps
it relates only to DEC OSF/1...  (manifests itself as scheduler crashing..)

	/Matti Aarnio <mea@nic.funet.fi>


*** mailbox.c.old	Fri Aug  9 16:55:22 EET DST 1996
--- mailbox.c	Sat Aug 10 02:21:15 EET DST 1996
***************
*** 51,56 ****
--- 51,62 ----
  #include <unistd.h>
  #endif
  
+ #if defined(HAVE_LOCKF) && defined(HAVE_FLOCK)
+ # ifdef __linux__
+ #  undef HAVE_FLOCK  /* At Linux it is not good to have BOTH of these */
+ # endif
+ #endif
+ 
  #ifdef	HAVE_LOCKF
  #ifdef	F_OK
  #undef	F_OK