]> git.sur5r.net Git - openldap/blobdiff - tests/progs/slapd-tester.c
Delete CDB (no transactions) support
[openldap] / tests / progs / slapd-tester.c
index 902b2953544c1bbb9452c17e5e3cbcf7ff03e5f8..e925feff59827d6b05e2205d00d85dc097bc9390 100644 (file)
@@ -1,3 +1,8 @@
+/* $OpenLDAP$ */
+/*
+ * Copyright 1998-2002 The OpenLDAP Foundation, All Rights Reserved.
+ * COPYING RESTRICTIONS APPLY, see COPYRIGHT file
+ */
 #include "portable.h"
 
 #include <stdio.h>
 
 #include <ac/ctype.h>
 #include <ac/dirent.h>
+#include <ac/param.h>
 #include <ac/socket.h>
 #include <ac/string.h>
 #include <ac/unistd.h>
 #include <ac/wait.h>
 
-#ifdef HAVE_SYS_PARAM_H
-#include <sys/param.h>
-#endif
 
 #include "ldap_defaults.h"
 
@@ -42,7 +45,7 @@ static void
 usage( char *name )
 {
        fprintf( stderr, "usage: %s [-h <host>] -p <port> -D <manager> -w <passwd> -d <datadir> -b <baseDN> [-j <maxchild>] [-l <loops>] -P <progdir>\n", name );
-       exit( 1 );
+       exit( EXIT_FAILURE );
 }
 
 int
@@ -130,7 +133,7 @@ main( int argc, char **argv )
 
                fprintf( stderr, "%s: couldn't open data directory \"%s\".\n",
                                        argv[0], dirname );
-               exit( 1 );
+               exit( EXIT_FAILURE );
 
        }
 
@@ -246,7 +249,7 @@ main( int argc, char **argv )
 
        wait4kids( -1 );
 
-       exit( 0 );
+       exit( EXIT_SUCCESS );
 }
 
 static char *
@@ -319,7 +322,7 @@ fork_child( char *prog, char *args[] )
                execvp( prog, args );
                fprintf( stderr, "%s: ", prog );
                perror( "execv" );
-               exit( -1 );
+               exit( EXIT_FAILURE );
                break;
 
        case -1:        /* trouble */