*/
#include "includes.h"
-#include "torture/torture.h"
#include "system/filesys.h"
#include "system/dir.h"
-#include "../tdb/include/tdb.h"
+#include <tdb.h>
#include "../lib/util/util_tdb.h"
#include "libcli/libcli.h"
#include "torture/util.h"
+#include "torture/basic/proto.h"
+
+#undef strcasecmp
static TDB_CONTEXT *tdb;
#define NAME_LENGTH 20
-static uint_t total, collisions, failures;
+static unsigned int total, collisions, failures;
static bool test_one(struct torture_context *tctx ,struct smbcli_state *cli,
const char *name)
static char *gen_name(TALLOC_CTX *mem_ctx)
{
const char *chars = "0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz._-$~...";
- uint_t max_idx = strlen(chars);
- uint_t len;
+ unsigned int max_idx = strlen(chars);
+ unsigned int len;
int i;
char *p;
char *name;
/* and a medium probability of a common lead string */
if ((len > 5) && (random() % 10 == 0)) {
- strncpy(p, "ABCDE", 5);
+ strlcpy(p, "ABCDE", 6);
}
/* and a high probability of a good extension length */