diff options
Diffstat (limited to 'source/torture')
-rw-r--r-- | source/torture/pdbtest.c | 2 | ||||
-rw-r--r-- | source/torture/torture.c | 4 |
2 files changed, 5 insertions, 1 deletions
diff --git a/source/torture/pdbtest.c b/source/torture/pdbtest.c index 8b15f9629b9..b51e36e3550 100644 --- a/source/torture/pdbtest.c +++ b/source/torture/pdbtest.c @@ -236,7 +236,7 @@ int main(int argc, char **argv) uint32 expire, min_age, history; struct pdb_methods *pdb; poptContext pc; - static char *backend = NULL; + static const char *backend = NULL; static const char *unix_user = "nobody"; struct poptOption long_options[] = { {"username", 'u', POPT_ARG_STRING, &unix_user, 0, "Unix user to use for testing", "USERNAME" }, diff --git a/source/torture/torture.c b/source/torture/torture.c index 5ab28438f21..925cac3f32c 100644 --- a/source/torture/torture.c +++ b/source/torture/torture.c @@ -369,6 +369,8 @@ static BOOL rw_torture(struct cli_state *c) char buf[1024]; BOOL correct = True; + memset(buf, '\0', sizeof(buf)); + fnum2 = cli_open(c, lockfname, O_RDWR | O_CREAT | O_EXCL, DENY_NONE); if (fnum2 == -1) @@ -1049,6 +1051,8 @@ static BOOL run_tcon_test(int dummy) char buf[4]; BOOL ret = True; + memset(buf, '\0', sizeof(buf)); + if (!torture_open_connection(&cli, 0)) { return False; } |