]> git.sur5r.net Git - openldap/commitdiff
Silence warnings: Remove unused variables. Enclose some initializers in in {}.
authorHallvard Furuseth <hallvard@openldap.org>
Tue, 9 Mar 1999 07:15:35 +0000 (07:15 +0000)
committerHallvard Furuseth <hallvard@openldap.org>
Tue, 9 Mar 1999 07:15:35 +0000 (07:15 +0000)
14 files changed:
servers/slapd/abandon.c
servers/slapd/acl.c
servers/slapd/aclparse.c
servers/slapd/attr.c
servers/slapd/backend.c
servers/slapd/bind.c
servers/slapd/compare.c
servers/slapd/daemon.c
servers/slapd/dn.c
servers/slapd/entry.c
servers/slapd/filter.c
servers/slapd/filterentry.c
servers/slapd/main.c
servers/slapd/monitor.c

index 4b5986e585eac6872d069a8ee85f445ae3f0d90e..ea29321b3f15ab316a5ef7178227967008fbd878 100644 (file)
@@ -26,7 +26,6 @@ do_abandon(
 )
 {
        int             id;
-       Backend         *be;
        Operation       *o;
 
        Debug( LDAP_DEBUG_TRACE, "do_abandon\n", 0, 0, 0 );
index d6e92eb53b42d643afb4004199f5cf986536ae0c..f029d3ccfd47b20005e9671cdef33d98c0fa6676 100644 (file)
@@ -107,7 +107,7 @@ acl_get_applicable(
     regmatch_t *matches
 )
 {
-       int             i, j;
+       int             i;
        struct acl      *a;
     char               *edn;
 
@@ -477,7 +477,6 @@ string_expand(
                        } else if (*sp >= '0' && *sp <= '9' ) {
                                int     n;
                                int     i;
-                               char   *ep;
                                int     l;
 
                                n = *sp - '0';
index b3741a0b70d9dac7c1a9e724a4ff4f9c65dfceb5..d89fb840351a9edc6ebb74c6f2c04d59e8eefdfd 100644 (file)
@@ -87,7 +87,7 @@ parse_acl(
 )
 {
        int             i;
-       char            *e, *left, *right;
+       char            *left, *right;
        struct acl      *a;
        struct access   *b;
 
index 50f170e0178e78ace8e76ce633bdcaf724a1034d..c1178c94e919005772ca5bb535f616829a8ba29d 100644 (file)
@@ -65,8 +65,6 @@ attr_merge_fast(
     Attribute          ***a
 )
 {
-       int             i;
-
        if ( *a == NULL ) {
                for ( *a = &e->e_attrs; **a != NULL; *a = &(**a)->a_next ) {
                        if ( strcasecmp( (**a)->a_type, type ) == 0 ) {
@@ -101,7 +99,6 @@ attr_merge(
     struct berval      **vals
 )
 {
-       int             i;
        Attribute       **a;
 
        for ( a = &e->e_attrs; *a != NULL; a = &(*a)->a_next ) {
@@ -263,7 +260,7 @@ attr_syntax_config(
 {
        char                    *save;
        struct asyntaxinfo      *a;
-       int                     i, lasti;
+       int                     lasti;
 
        if ( argc < 2 ) {
                Debug( LDAP_DEBUG_ANY,
index 9f9f82f45e6152311532fe6060756f55d32608d7..ed09a15ac1cd21364b1e673b4a02d079d2f5d903 100644 (file)
@@ -453,8 +453,6 @@ be_isroot( Backend *be, char *ndn )
 char *
 be_root_dn( Backend *be )
 {
-       int rc;
-
        if ( be->be_root_dn == NULL ) {
                return( "" );
        }
index 3e69c967e323fb46544c962c79bf1fb8e319884b..cf0b2af328eb65760cf0bdbc633c703acc35942a 100644 (file)
@@ -28,7 +28,7 @@ do_bind(
 )
 {
        BerElement      *ber = op->o_ber;
-       int             version, method, len;
+       int             version, method;
        char            *cdn, *ndn;
        unsigned long   rc;
        struct berval   cred;
index 45461d56876c4c8a3eaba4ad95ea503b3a60312b..0d1c50abdbc02cc6fc7e704dde993b5c152316a1 100644 (file)
@@ -26,7 +26,6 @@ do_compare(
 {
        char    *ndn;
        Ava     ava;
-       int     rc;
        Backend *be;
 
        Debug( LDAP_DEBUG_TRACE, "do_compare\n", 0, 0, 0 );
index 807b705d875c0acb923294b667f96468d016e90b..c58ed25bca93d3a5fa52725010727b7d515b8e20 100644 (file)
@@ -53,16 +53,12 @@ slapd_daemon(
     void *port
 )
 {
-       Operation               *o;
-       BerElement              ber;
-       unsigned long           len, tag, msgid;
        int                     i;
        int                     tcps, ns;
        struct sockaddr_in      addr;
        fd_set                  readfds;
        fd_set                  writefds;
        FILE                    *fp;
-       int                     on = 1;
 
 #ifdef HAVE_SYSCONF
        dtblsize = sysconf( _SC_OPEN_MAX );
@@ -150,7 +146,7 @@ slapd_daemon(
                struct hostent          *hp;
                struct timeval          zero;
                struct timeval          *tvp;
-               int                     len, pid;
+               int                     len;
                int                     data_ready;
 
                char    *client_name;
index 2d02628ed3f86ba93acbcad1f1a42b0783691599..57d8788ecd72d6d4b7467bcf871de64964f906f8 100644 (file)
@@ -155,7 +155,7 @@ dn_parent(
 )
 {
        char    *s;
-       int     inquote, gotesc;
+       int     inquote;
 
        if( dn == NULL ) {
                return NULL;
@@ -225,7 +225,7 @@ char * dn_rdn(
     char       *dn )
 {
        char    *s;
-       int     inquote, gotesc;
+       int     inquote;
 
        if( dn == NULL ) {
                return NULL;
index 61f315a507e4b9bba71e9d9a2532dfd44ff489c6..563e01cec113c893c12e15919146340f9606fa57 100644 (file)
@@ -217,7 +217,6 @@ entry2str(
 void
 entry_free( Entry *e )
 {
-       int             i;
        Attribute       *a, *next;
 
        if ( e->e_dn != NULL ) {
index dff90b0446a16ccdbdb16f54dd2528c13168b416..2a977940e18a4b5f4c3510a0bba60e0ef6edc3a9 100644 (file)
@@ -15,7 +15,7 @@ static int    get_substring_filter(Connection *conn, BerElement *ber, Filter *f, ch
 int
 get_filter( Connection *conn, BerElement *ber, Filter **filt, char **fstr )
 {
-       unsigned long   tag, len;
+       unsigned long   len;
        int             err;
        Filter          *f;
        char            *ftmp;
index a6528b2877bc4a11841dc6aa5c258c9ee51d6aa9..738b66f5b31807eb9e89c508e0307e2d86d50cbb 100644 (file)
@@ -179,7 +179,7 @@ test_approx_filter(
 )
 {
        char            *w1, *w2, *c1, *c2;
-       int             i, rc, match;
+       int             i;
        Attribute       *a;
 
        if ( be != NULL && ! access_allowed( be, conn, op, e,
@@ -256,7 +256,7 @@ test_filter_list(
     int                ftype
 )
 {
-       int     rc, nomatch;
+       int     nomatch;
        Filter  *f;
 
        Debug( LDAP_DEBUG_FILTER, "=> test_filter_list\n", 0, 0, 0 );
index f4ca8a58b052680100340f48a672a68f7db3bc24..0d13c4be683e0ac2f15d4c931a5ebf08ab1aa13f 100644 (file)
@@ -38,7 +38,7 @@ static STRDISP  syslog_types[] = {
     { "LOCAL5",         6, LOG_LOCAL5 },
     { "LOCAL6",         6, LOG_LOCAL6 },
     { "LOCAL7",         6, LOG_LOCAL7 },
-    NULL
+    { NULL }
 };
 
 static int   cnvt_str2int( char *, STRDISP_P, int );
@@ -236,7 +236,6 @@ main( int argc, char **argv )
 
        } else {
                Connection              c;
-               Operation               *o;
                BerElement              ber;
                unsigned long           len, tag;
                long                    msgid;
index 62effcda9ecac32aaafb86dd702748d07e20d980..f065df6975767c8e70fc33d6537ec7a2435ae4a6 100644 (file)
@@ -39,7 +39,7 @@ monitor_info( Connection *conn, Operation *op )
        struct berval   *vals[2];
        int             i, nconns, nwritewaiters, nreadwaiters;
        struct tm       *ltm;
-       char            *p, *tmpdn;
+       char            *p;
 
        vals[0] = &val;
        vals[1] = NULL;