summaryrefslogtreecommitdiff
path: root/source3/torture
diff options
context:
space:
mode:
authorStefan Metzmacher <metze@samba.org>2014-09-26 03:13:28 +0200
committerAndrew Bartlett <abartlet@samba.org>2014-10-17 12:57:07 +0200
commit40bc651f95061fdd27db8b0ce4da0e38c209c3db (patch)
tree4b69012132cdd71de34498c6b6ea515cb4c3d9b7 /source3/torture
parent71432b9eda6e36222a3fcfcdc185a2459fb07541 (diff)
downloadsamba-40bc651f95061fdd27db8b0ce4da0e38c209c3db.tar.gz
s3:torture: avoid unused cli_set_username()
Change-Id: Ia774b256093aff5f2b3338e7827e2d798fb06a96 Signed-off-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Diffstat (limited to 'source3/torture')
-rw-r--r--source3/torture/torture.c6
1 files changed, 0 insertions, 6 deletions
diff --git a/source3/torture/torture.c b/source3/torture/torture.c
index deb0e60a2f5..2cd63e113c8 100644
--- a/source3/torture/torture.c
+++ b/source3/torture/torture.c
@@ -411,12 +411,10 @@ bool torture_init_connection(struct cli_state **pcli)
bool torture_cli_session_setup2(struct cli_state *cli, uint16 *new_vuid)
{
uint16_t old_vuid = cli_state_get_uid(cli);
- fstring old_user_name;
size_t passlen = strlen(password);
NTSTATUS status;
bool ret;
- fstrcpy(old_user_name, cli->user_name);
cli_state_set_uid(cli, 0);
ret = NT_STATUS_IS_OK(cli_session_setup(cli, username,
password, passlen,
@@ -424,10 +422,6 @@ bool torture_cli_session_setup2(struct cli_state *cli, uint16 *new_vuid)
workgroup));
*new_vuid = cli_state_get_uid(cli);
cli_state_set_uid(cli, old_vuid);
- status = cli_set_username(cli, old_user_name);
- if (!NT_STATUS_IS_OK(status)) {
- return false;
- }
return ret;
}