handle incomplete load files
authorAndrew Tridgell <tridge@samba.org>
Tue, 9 Mar 2004 02:24:14 +0000 (02:24 +0000)
committerAndrew Tridgell <tridge@samba.org>
Tue, 9 Mar 2004 02:24:14 +0000 (02:24 +0000)
change default timelimit to 600 secs
(This used to be commit c5c75a6adab10e35584dca760586fda333ca5308)

source4/torture/nbench/nbench.c
source4/torture/nbench/nbio.c

index 6b0e78e1ab4f610c4219a30228a27f11c8a60e8a..3da7dedae138044b26c6e2c80a8fb53c6ce633c3 100644 (file)
@@ -21,8 +21,8 @@
 #include "includes.h"
 
 int nbench_line_count = 0;
-static int timelimit = 300;
-static const char *loadfile;
+static int timelimit = 600;
+static char *loadfile;
 
 #define ival(s) strtol(s, NULL, 0)
 
@@ -188,5 +188,3 @@ BOOL torture_nbench(int dummy)
               1.0e-6 * nbio_total() / t);
        return correct;
 }
-
-
index 819383b7d856e6679cccf5ac88f55cbb33f8b088..4ce3ea011b9dfe803fb36861f28edbb111333e1c 100644 (file)
@@ -22,7 +22,7 @@
 
 #include "includes.h"
 
-#define MAX_FILES 1000
+#define MAX_FILES 100
 
 extern int nbench_line_count;
 static int nbio_id;
@@ -557,6 +557,10 @@ void nb_deltree(const char *dname)
 {
        int total_deleted;
 
+       smb_raw_exit(c->session);
+
+       ZERO_STRUCT(ftable);
+
        total_deleted = cli_deltree(c->tree, dname);
 
        if (total_deleted == -1) {
@@ -570,7 +574,6 @@ void nb_deltree(const char *dname)
 void nb_cleanup(const char *cname)
 {
        char *dname = NULL;
-       smb_raw_exit(c->session);
        asprintf(&dname, "\\clients\\%s", cname);
        nb_deltree(dname);
        free(dname);