]> git.sur5r.net Git - openldap/commitdiff
s/NULLMSG/NULL/
authorKurt Zeilenga <kurt@openldap.org>
Wed, 19 May 1999 07:14:27 +0000 (07:14 +0000)
committerKurt Zeilenga <kurt@openldap.org>
Wed, 19 May 1999 07:14:27 +0000 (07:14 +0000)
Fix ldappasswd timeval.

clients/fax500/main.c
clients/gopher/go500.c
clients/gopher/go500gw.c
clients/mail500/main.c
clients/rcpt500/query.c
clients/tools/ldappasswd.c

index 5cd49dbf812eb6deb4663253c21cf06842c99163..1c090da495ae35b475682557dd562766f60e3a1d 100644 (file)
@@ -439,7 +439,7 @@ do_address(
 
        /* no matches - bounce with user unknown */
        if ( match == 0 ) {
-               add_error( err, nerr, E_USERUNKNOWN, name, NULLMSG );
+               add_error( err, nerr, E_USERUNKNOWN, name, NULL );
                return;
        }
 
@@ -775,7 +775,7 @@ do_group_members(
 
                                                add_error( err, nerr,
                                                    E_JOINMEMBERNOFAXNUM, ndn, 
-                                                   NULLMSG );
+                                                   NULL );
 
                                                free( ndn );
                                        }
@@ -793,7 +793,7 @@ do_group_members(
 
                                                add_error( err, nerr,
                                                    E_JOINMEMBERNOEMAIL, ndn, 
-                                                   NULLMSG );
+                                                   NULL );
 
                                                free( ndn );
                                        }
@@ -835,7 +835,7 @@ add_member(
        if ( (rc = ldap_search_st( ld, dn, LDAP_SCOPE_BASE, "(objectclass=*)",
            attrs, 0, &timeout, &res )) != LDAP_SUCCESS ) {
                if ( rc == LDAP_NO_SUCH_OBJECT ) {
-                       add_error( err, nerr, E_BADMEMBER, dn, NULLMSG );
+                       add_error( err, nerr, E_BADMEMBER, dn, NULL );
 
                        return;
                } else {
@@ -885,7 +885,7 @@ add_member(
                        ldap_value_free( mail );
                        ldap_msgfree( res );
                } else {
-                       add_error( err, nerr, E_MEMBERNOFAXNUM, ndn, NULLMSG );
+                       add_error( err, nerr, E_MEMBERNOFAXNUM, ndn, NULL );
                }
                break;
        case MAIL500 :
@@ -897,7 +897,7 @@ add_member(
 
                /* else generate a bounce */
                } else {
-                       add_error( err, nerr, E_MEMBERNOEMAIL, ndn, NULLMSG );
+                       add_error( err, nerr, E_MEMBERNOEMAIL, ndn, NULL );
                }
 
                free( ndn );
@@ -923,7 +923,7 @@ do_group_request(
 
                ldap_value_free( requeststo );
        } else {
-               add_error( err, nerr, E_NOREQUEST, dn, NULLMSG );
+               add_error( err, nerr, E_NOREQUEST, dn, NULL );
        }
 }
 
@@ -945,7 +945,7 @@ do_group_errors(
 
                ldap_value_free( errorsto );
        } else {
-               add_error( err, nerr, E_NOERRORS, dn, NULLMSG );
+               add_error( err, nerr, E_NOERRORS, dn, NULL );
        }
 }
 
index fa9d9b37a26bcc77edab761c2c17898bd0303ba6..706da3c40e2f51c6d792dae045e1d81a4de2e6d6 100644 (file)
@@ -367,7 +367,7 @@ do_queries( int s )
        if ( debug ) {
                fprintf( stderr, "got %d bytes\n", len );
 #ifdef LDAP_DEBUG
-               lber_bprint( buf, len );
+               ber_bprint( buf, len );
 #endif
        }
 
index eeb4784fdb19698c9363addaf5d02e6098782c49..058ada1fcc51c9984750449de7ffc19bab85c01a 100644 (file)
@@ -396,7 +396,7 @@ do_queries( int s )
        if ( debug ) {
                fprintf( stderr, "got %d bytes\n", len );
 #ifdef LDAP_DEBUG
-               lber_bprint( buf, len );
+               ber_bprint( buf, len );
 #endif
        }
 
index c379a46c267fd636f9e4d7732da060a9649297b6..f7a9993035de4e912e97bd8a8a64f87d6a3fff57 100644 (file)
@@ -514,9 +514,9 @@ do_address(
        /* no matches - bounce with user unknown */
        if ( match == 0 ) {
                if ( type == USER ) {
-                       add_error( err, nerr, E_USERUNKNOWN, name, NULLMSG );
+                       add_error( err, nerr, E_USERUNKNOWN, name, NULL );
                } else {
-                       add_error( err, nerr, E_GROUPUNKNOWN, name, NULLMSG );
+                       add_error( err, nerr, E_GROUPUNKNOWN, name, NULL );
                }
                return;
        }
@@ -836,7 +836,7 @@ do_group_members(
                if ( strcasecmp( joinable[0], "FALSE" ) == 0 ) {
                        if ( ! anymembers ) {
                                add_error( err, nerr, E_NOMEMBERS, dn,
-                                   NULLMSG );
+                                   NULL );
                        }
 
                        ldap_value_free( joinable );
@@ -903,7 +903,7 @@ do_group_members(
                                        ndn = ldap_get_dn( ld, ee );
 
                                        add_error( err, nerr,
-                                           E_JOINMEMBERNOEMAIL, ndn, NULLMSG );
+                                           E_JOINMEMBERNOEMAIL, ndn, NULL );
 
                                        free( ndn );
                                }
@@ -916,7 +916,7 @@ do_group_members(
        }
 
        if ( ! anymembers ) {
-               add_error( err, nerr, E_NOMEMBERS, dn, NULLMSG );
+               add_error( err, nerr, E_NOMEMBERS, dn, NULL );
        }
 }
 
@@ -944,7 +944,7 @@ add_member(
        if ( (rc = ldap_search_st( ld, dn, LDAP_SCOPE_BASE, "(objectclass=*)",
            attrs, 0, &timeout, &res )) != LDAP_SUCCESS ) {
                if ( rc == LDAP_NO_SUCH_OBJECT ) {
-                       add_error( err, nerr, E_BADMEMBER, dn, NULLMSG );
+                       add_error( err, nerr, E_BADMEMBER, dn, NULL );
 
                        return;
                } else {
@@ -983,7 +983,7 @@ add_member(
        } else {
                if ( suppress == NULL || strcasecmp( suppress[0], "FALSE" )
                    == 0 ) {
-                       add_error( err, nerr, E_MEMBERNOEMAIL, ndn, NULLMSG );
+                       add_error( err, nerr, E_MEMBERNOEMAIL, ndn, NULL );
                }
        }
 
@@ -1008,7 +1008,7 @@ do_group_request(
 
                ldap_value_free( requeststo );
        } else {
-               add_error( err, nerr, E_NOREQUEST, dn, NULLMSG );
+               add_error( err, nerr, E_NOREQUEST, dn, NULL );
        }
 }
 
@@ -1030,7 +1030,7 @@ do_group_errors(
 
                ldap_value_free( errorsto );
        } else {
-               add_error( err, nerr, E_NOERRORS, dn, NULLMSG );
+               add_error( err, nerr, E_NOERRORS, dn, NULL );
        }
 }
 
@@ -1050,7 +1050,7 @@ do_group_owner(
                add_to( to, nto, owner );
                ldap_value_free( owner );
        } else {
-               add_error( err, nerr, E_NOOWNER, dn, NULLMSG );
+               add_error( err, nerr, E_NOOWNER, dn, NULL );
        }
 }
 
index b82f5215d96e91811d773b93722be88ca569eda9..51fdf8312e6490f5b9efebce7d1b79de93e0a4a7 100644 (file)
@@ -305,7 +305,7 @@ do_read( LDAP *ldp, char *dn, char *reply, struct ldap_disptmpl *tmpll )
     static char        **defvals[] = { maildefvals, NULL };
 
 
-    rc = ldap_entry2text_search( ldp, dn, searchbase, NULLMSG, tmpll,
+    rc = ldap_entry2text_search( ldp, dn, searchbase, NULL, tmpll,
            defattrs, defvals, append_text, (void *)reply, "\n",
            rdncount, LDAP_DISP_OPT_DOSEARCHACTIONS );
 
index 4b5ac508a08f5fda2f85e2a76992be01b6ec3368..6bbe6ab5c93b30f1d4aee57905eddc189a25b349 100644 (file)
@@ -570,9 +570,11 @@ main (int argc, char *argv[])
        /* this is of questionable value
         * gettimeofday not provide much usec
         */
-       struct timeval  tv;
-       gettimeofday (&tv, NULL);
-       srand (tv.tv_usec);
+       {
+               struct timeval tv;
+               gettimeofday (&tv, NULL);
+               srand (tv.tv_usec);
+       }
 #else
        /* The traditional seed */
        srand((unsigned)time( NULL ));