summaryrefslogtreecommitdiff
path: root/source3/rpc_client
diff options
context:
space:
mode:
authorAndrew Bartlett <abartlet@samba.org>2004-03-27 05:39:19 +0000
committerAndrew Bartlett <abartlet@samba.org>2004-03-27 05:39:19 +0000
commit59572d1297ca5c11067e98a8a01199d5f49c02f8 (patch)
treec9441f5e6411d45feb24846470ced4c41666b6d1 /source3/rpc_client
parentdeee8fae47be8722f737d4a2583e93f85658c126 (diff)
downloadsamba-59572d1297ca5c11067e98a8a01199d5f49c02f8.tar.gz
samba-59572d1297ca5c11067e98a8a01199d5f49c02f8.tar.bz2
samba-59572d1297ca5c11067e98a8a01199d5f49c02f8.zip
Ensure we correctly set cli->nt_pipe_fnum on failure to correctly open the
NT session. Andrew Bartlett (This used to be commit 01fff20e6e0212e9f70a5a66c3e46f7079b342f1)
Diffstat (limited to 'source3/rpc_client')
-rw-r--r--source3/rpc_client/cli_pipe.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/source3/rpc_client/cli_pipe.c b/source3/rpc_client/cli_pipe.c
index f425a24d08..df0d37a463 100644
--- a/source3/rpc_client/cli_pipe.c
+++ b/source3/rpc_client/cli_pipe.c
@@ -1453,6 +1453,7 @@ BOOL cli_nt_session_open(struct cli_state *cli, const int pipe_idx)
DEBUG(0,("cli_nt_session_open: pipe hnd state failed. Error was %s\n",
cli_errstr(cli)));
cli_close(cli, cli->nt_pipe_fnum);
+ cli->nt_pipe_fnum = 0;
return False;
}
}
@@ -1463,6 +1464,7 @@ BOOL cli_nt_session_open(struct cli_state *cli, const int pipe_idx)
DEBUG(2,("cli_nt_session_open: rpc bind to %s failed\n",
get_pipe_name_from_index(pipe_idx)));
cli_close(cli, cli->nt_pipe_fnum);
+ cli->nt_pipe_fnum = 0;
return False;
}