Print this page
3188 ignore the comment in limits.h and define NAME_MAX
Reviewed by: Jason King <jason.brian.king@gmail.com>
Reviewed by: Peter Tribble <peter.tribble@gmail.com>
Reviewed by: Sam Zaydel <szaydel@racktopsystems.com>

Split Close
Expand all
Collapse all
          --- old/usr/src/cmd/ypcmd/ypsym.h
          +++ new/usr/src/cmd/ypcmd/ypsym.h
↓ open down ↓ 26 lines elided ↑ open up ↑
  27   27  /*        All Rights Reserved   */
  28   28  
  29   29  /*
  30   30   * Portions of this source code were derived from Berkeley 4.3 BSD
  31   31   * under license from the Regents of the University of California.
  32   32   */
  33   33  
  34   34  #ifndef __YPSYM_H
  35   35  #define __YPSYM_H
  36   36  
  37      -#pragma ident   "%Z%%M% %I%     %E% SMI"
  38      -
  39   37  #ifdef  __cplusplus
  40   38  extern "C" {
  41   39  #endif
  42   40  
  43   41  /*
  44   42   * This contains symbol and structure definitions for modules in the YP server
  45   43   */
  46   44  
  47   45  #include <ndbm.h>                       /* Pull this in first */
  48   46  #define DATUM
↓ open down ↓ 109 lines elided ↑ open up ↑
 158  156  
 159  157  /* definitions for reading files of lists */
 160  158  
 161  159  struct listofnames
 162  160  {
 163  161          struct listofnames *nextname;
 164  162          char *name;
 165  163  };
 166  164  typedef struct listofnames listofnames;
 167  165  
 168      -/*
 169      - * XXX- NAME_MAX can't be defined in <limits.h> in a POSIX conformant system
 170      - *      (under conditions which apply to Sun systems). Removal of this define
 171      - *      caused yp to break (and only yp!). Hence, NAME_MAX is defined here
 172      - *      *exactly* as it was in <limits.h>. I suspect this may not be the
 173      - *      desired value. I suspect the desired value is either:
 174      - *              - the maxumum name length for any file system type, or
 175      - *              - should be _POSIX_NAME_MAX which is the minimum-maximum name
 176      - *                length in a POSIX conformant system (which just happens to
 177      - *                be 14), or
 178      - *              - should be gotten by pathconf() or fpathconf().
 179      - * XXX- I leave this to the owners of yp!
 180      - */
 181      -#define NAME_MAX        14      /* s5 file system maximum name length */
 182      -
 183  166  #ifdef  __cplusplus
 184  167  }
 185  168  #endif
 186  169  
 187  170  #endif  /* __YPSYM_H */
    
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX