Print this page
6136 sysmacros.h unnecessarily polutes the namespace
   1 /*
   2  * Copyright (c) 1998-2009 Sendmail, Inc. and its suppliers.
   3  *      All rights reserved.
   4  * Copyright (c) 1983, 1995-1997 Eric P. Allman.  All rights reserved.
   5  * Copyright (c) 1988, 1993
   6  *      The Regents of the University of California.  All rights reserved.
   7  *
   8  * By using this file, you agree to the terms and conditions set
   9  * forth in the LICENSE file which can be found at the top level of
  10  * the sendmail distribution.
  11  *
  12  */
  13 
  14 #include <sendmail.h>
  15 #include <sm/sem.h>
  16 
  17 SM_RCSID("@(#)$Id: queue.c,v 8.987 2009/12/18 17:08:01 ca Exp $")
  18 


  19 #include <dirent.h>
  20 
  21 # define RELEASE_QUEUE  (void) 0
  22 # define ST_INODE(st)   (st).st_ino
  23 
  24 #  define sm_file_exists(errno) ((errno) == EEXIST)
  25 
  26 # if HASFLOCK && defined(O_EXLOCK)
  27 #   define SM_OPEN_EXLOCK 1
  28 #   define TF_OPEN_FLAGS (O_CREAT|O_WRONLY|O_EXCL|O_EXLOCK)
  29 # else /* HASFLOCK && defined(O_EXLOCK) */
  30 #  define TF_OPEN_FLAGS (O_CREAT|O_WRONLY|O_EXCL)
  31 # endif /* HASFLOCK && defined(O_EXLOCK) */
  32 
  33 #ifndef SM_OPEN_EXLOCK
  34 # define SM_OPEN_EXLOCK 0
  35 #endif /* ! SM_OPEN_EXLOCK */
  36 
  37 /*
  38 **  Historical notes:


   1 /*
   2  * Copyright (c) 1998-2009 Sendmail, Inc. and its suppliers.
   3  *      All rights reserved.
   4  * Copyright (c) 1983, 1995-1997 Eric P. Allman.  All rights reserved.
   5  * Copyright (c) 1988, 1993
   6  *      The Regents of the University of California.  All rights reserved.
   7  *
   8  * By using this file, you agree to the terms and conditions set
   9  * forth in the LICENSE file which can be found at the top level of
  10  * the sendmail distribution.
  11  *
  12  */
  13 
  14 #include <sendmail.h>
  15 #include <sm/sem.h>
  16 
  17 SM_RCSID("@(#)$Id: queue.c,v 8.987 2009/12/18 17:08:01 ca Exp $")
  18 
  19 #include <sys/types.h>
  20 #include <sys/mkdev.h>
  21 #include <dirent.h>
  22 
  23 # define RELEASE_QUEUE  (void) 0
  24 # define ST_INODE(st)   (st).st_ino
  25 
  26 #  define sm_file_exists(errno) ((errno) == EEXIST)
  27 
  28 # if HASFLOCK && defined(O_EXLOCK)
  29 #   define SM_OPEN_EXLOCK 1
  30 #   define TF_OPEN_FLAGS (O_CREAT|O_WRONLY|O_EXCL|O_EXLOCK)
  31 # else /* HASFLOCK && defined(O_EXLOCK) */
  32 #  define TF_OPEN_FLAGS (O_CREAT|O_WRONLY|O_EXCL)
  33 # endif /* HASFLOCK && defined(O_EXLOCK) */
  34 
  35 #ifndef SM_OPEN_EXLOCK
  36 # define SM_OPEN_EXLOCK 0
  37 #endif /* ! SM_OPEN_EXLOCK */
  38 
  39 /*
  40 **  Historical notes: