]> git.sur5r.net Git - openldap/commitdiff
pw_gecos depends on HAVE_PW_GECOS
authorHoward Chu <hyc@openldap.org>
Fri, 19 Jul 2002 14:25:37 +0000 (14:25 +0000)
committerHoward Chu <hyc@openldap.org>
Fri, 19 Jul 2002 14:25:37 +0000 (14:25 +0000)
libraries/librewrite/map.c

index 8db54af13711b89701804bb6fdcf5a214cf20012..5ada2c17d23092e85c71ee92e43005d45de3b4bd 100644 (file)
@@ -541,6 +541,7 @@ rewrite_xmap_apply(
                        break;
                }
 
+#ifdef HAVE_PW_GECOS
                if ( pwd->pw_gecos != NULL && pwd->pw_gecos[0] != '\0' ) {
                        int l = strlen( pwd->pw_gecos );
                        
@@ -555,7 +556,9 @@ rewrite_xmap_apply(
                                break;
                        }
                        val->bv_len = l;
-               } else {
+               } else
+#endif /* HAVE_PW_GECOS */
+               {
                        val->bv_val = strdup( key->bv_val );
                        val->bv_len = key->bv_len;
                }