Print this page
2989 Eliminate use of LOGNAME_MAX in ON
1166 useradd have warning with name more 8 chars

Split Close
Expand all
Collapse all
          --- old/usr/src/lib/nsswitch/ldap/common/getnetgrent.c
          +++ new/usr/src/lib/nsswitch/ldap/common/getnetgrent.c
↓ open down ↓ 11 lines elided ↑ open up ↑
  12   12   *
  13   13   * When distributing Covered Code, include this CDDL HEADER in each
  14   14   * file and include the License file at usr/src/OPENSOLARIS.LICENSE.
  15   15   * If applicable, add the following below this CDDL HEADER, with the
  16   16   * fields enclosed by brackets "[]" replaced with your own identifying
  17   17   * information: Portions Copyright [yyyy] [name of copyright owner]
  18   18   *
  19   19   * CDDL HEADER END
  20   20   */
  21   21  /*
       22 + * Copyright (c) 2013 Gary Mills
       23 + *
  22   24   * Copyright 2009 Sun Microsystems, Inc.  All rights reserved.
  23   25   * Use is subject to license terms.
  24   26   */
  25   27  
  26   28  
  27   29  #include <syslog.h>
  28   30  #include "ldap_common.h"
  29   31  
  30   32  /* netgroup attributes filters */
  31   33  #define _N_TRIPLE               "nisnetgrouptriple"
  32   34  #define _N_MEMBER               "membernisnetgroup"
  33   35  
  34   36  #define PRINT_VAL(a)            (((a).argc == 0) || ((a).argv == NULL) || \
  35   37                                      ((a).argv[0] == NULL)) ? "*" : (a).argv[0]
  36   38  #define ISNULL(a)               (a == NULL ? "<NULL>" : a)
  37   39  #define MAX_DOMAIN_LEN          1024
  38      -#define MAX_TRIPLE_LEN          (MAXHOSTNAMELEN + LOGNAME_MAX + \
       40 +#define MAX_TRIPLE_LEN          (MAXHOSTNAMELEN + LOGNAME_MAX_ILLUMOS + \
  39   41                                          MAX_DOMAIN_LEN + 5)
  40   42  
  41   43  #define _F_SETMEMBER            "(&(objectClass=nisNetGroup)(cn=%s))"
  42   44  #define _F_SETMEMBER_SSD        "(&(%%s)(cn=%s))"
  43   45  
  44   46  #define N_HASH          257
  45   47  #define COMMA           ','
  46   48  
  47   49  static const char *netgrent_attrs[] = {
  48   50          _N_TRIPLE,
↓ open down ↓ 984 lines elided ↑ open up ↑
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX