From 5d66d43667f9356b50dad5555e6b5ed04b7a4fd2 Mon Sep 17 00:00:00 2001 From: Tim Prouty Date: Wed, 21 Oct 2009 16:51:17 -0700 Subject: s4 torture: Fix the streams create disposition tests to actually return an error on failure --- source4/torture/raw/streams.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'source4') diff --git a/source4/torture/raw/streams.c b/source4/torture/raw/streams.c index 5c346f6de9..f2bf15756c 100644 --- a/source4/torture/raw/streams.c +++ b/source4/torture/raw/streams.c @@ -1358,7 +1358,7 @@ static bool test_stream_create_disposition(struct torture_context *tctx, const char *fname_stream; const char *default_stream_name = "::$DATA"; const char *stream_list[2]; - bool ret = true; + bool ret = false; int fnum = -1; fname_stream = talloc_asprintf(mem_ctx, "%s:%s", fname, stream); @@ -1457,7 +1457,7 @@ static bool test_stream_create_disposition(struct torture_context *tctx, status = smb_raw_open(cli->tree, mem_ctx, &io); CHECK_STATUS(status, NT_STATUS_OK); smbcli_close(cli->tree, io.ntcreatex.out.file.fnum); - if (!check_stream_list(cli, fname, 1, &default_stream_name)) { + if (!check_stream_list(cli, fname, 2, stream_list)) { goto done; } @@ -1488,6 +1488,8 @@ static bool test_stream_create_disposition(struct torture_context *tctx, goto done; } + ret = true; + done: smbcli_close(cli->tree, fnum); smbcli_unlink(cli->tree, fname); -- cgit