summaryrefslogtreecommitdiff
path: root/source3/torture/masktest.c
diff options
context:
space:
mode:
Diffstat (limited to 'source3/torture/masktest.c')
-rw-r--r--source3/torture/masktest.c9
1 files changed, 8 insertions, 1 deletions
diff --git a/source3/torture/masktest.c b/source3/torture/masktest.c
index 0d6c0b16f2..e98cf81f33 100644
--- a/source3/torture/masktest.c
+++ b/source3/torture/masktest.c
@@ -170,6 +170,7 @@ static struct cli_state *connect_one(char *share)
char *server_n;
char *server;
struct in_addr ip;
+ NTSTATUS status;
server = share+2;
share = strchr_m(server,'\\');
@@ -188,11 +189,17 @@ static struct cli_state *connect_one(char *share)
zero_ip(&ip);
/* have to open a new connection */
- if (!(c=cli_initialise()) || !cli_connect(c, server_n, &ip)) {
+ if (!(c=cli_initialise())) {
DEBUG(0,("Connection to %s failed\n", server_n));
return NULL;
}
+ status = cli_connect(c, server_n, &ip);
+ if (!NT_STATUS_IS_OK(status)) {
+ DEBUG(0,("Connection to %s failed. Error %s\n", server_n, nt_errstr(status) ));
+ return NULL;
+ }
+
c->protocol = max_protocol;
if (!cli_session_request(c, &calling, &called)) {