From 4b0af9be9a887b78a71eda26d418546330889ed1 Mon Sep 17 00:00:00 2001 From: Jeremy Allison Date: Wed, 9 Feb 2011 15:06:40 -0800 Subject: Make it clear we're using the open file pathname. Autobuild-User: Jeremy Allison Autobuild-Date: Thu Feb 10 01:06:29 CET 2011 on sn-devel-104 --- source3/smbd/smb2_find.c | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) (limited to 'source3/smbd') diff --git a/source3/smbd/smb2_find.c b/source3/smbd/smb2_find.c index 9a74886058..1ee493b906 100644 --- a/source3/smbd/smb2_find.c +++ b/source3/smbd/smb2_find.c @@ -227,7 +227,6 @@ static struct tevent_req *smbd_smb2_find_send(TALLOC_CTX *mem_ctx, int off = 0; uint32_t num = 0; uint32_t dirtype = aHIDDEN | aSYSTEM | aDIR; - const char *directory; bool dont_descend = false; bool ask_sharemode = true; @@ -266,8 +265,6 @@ static struct tevent_req *smbd_smb2_find_send(TALLOC_CTX *mem_ctx, return tevent_req_post(req, ev); } - directory = fsp->fsp_name->base_name; - if (strcmp(in_file_name, "") == 0) { tevent_req_nterror(req, NT_STATUS_OBJECT_NAME_INVALID); return tevent_req_post(req, ev); @@ -332,7 +329,7 @@ static struct tevent_req *smbd_smb2_find_send(TALLOC_CTX *mem_ctx, status = dptr_create(conn, fsp, - directory, + fsp->fsp_name->base_name, false, /* old_handle */ false, /* expect_close */ 0, /* spid */ @@ -382,9 +379,10 @@ static struct tevent_req *smbd_smb2_find_send(TALLOC_CTX *mem_ctx, DEBUG(8,("smbd_smb2_find_send: dirpath=<%s> dontdescend=<%s>, " "in_output_buffer_length = %u\n", - directory, lp_dontdescend(SNUM(conn)), + fsp->fsp_name->base_name, lp_dontdescend(SNUM(conn)), (unsigned int)in_output_buffer_length )); - if (in_list(directory,lp_dontdescend(SNUM(conn)),conn->case_sensitive)) { + if (in_list(fsp->fsp_name->base_name,lp_dontdescend(SNUM(conn)), + conn->case_sensitive)) { dont_descend = true; } -- cgit