summaryrefslogtreecommitdiff
path: root/source4
diff options
context:
space:
mode:
authorMatthias Dieter Wallnöfer <mwallnoefer@yahoo.de>2010-03-03 18:26:15 +0100
committerMatthias Dieter Wallnöfer <mwallnoefer@yahoo.de>2010-03-03 18:43:23 +0100
commit9b4d208ce8482e63a56fff3447179ff786062c48 (patch)
tree32a860782c45d29f780f3574d4d67747a6a09ded /source4
parenta21b49bb389f8f98fe43a6abe3b0fde51ec43210 (diff)
downloadsamba-9b4d208ce8482e63a56fff3447179ff786062c48.tar.gz
samba-9b4d208ce8482e63a56fff3447179ff786062c48.tar.bz2
samba-9b4d208ce8482e63a56fff3447179ff786062c48.zip
s4:srvsvc RPC - fix up the "ntvfs_connect" in "srvsvc_create_ntvfs_connect"
This should be the right fix (set the service name in the tcon union to the share name/path). That should be the solution for bug #6784.
Diffstat (limited to 'source4')
-rw-r--r--source4/rpc_server/srvsvc/srvsvc_ntvfs.c8
1 files changed, 5 insertions, 3 deletions
diff --git a/source4/rpc_server/srvsvc/srvsvc_ntvfs.c b/source4/rpc_server/srvsvc/srvsvc_ntvfs.c
index 7b337063af..17c5f81e65 100644
--- a/source4/rpc_server/srvsvc/srvsvc_ntvfs.c
+++ b/source4/rpc_server/srvsvc/srvsvc_ntvfs.c
@@ -57,6 +57,7 @@ NTSTATUS srvsvc_create_ntvfs_context(struct dcesrv_call_state *dce_call,
struct share_context *sctx;
struct share_config *scfg;
const char *sharetype;
+ union smb_tcon tcon;
status = share_get_context_by_name(mem_ctx, lp_share_backend(dce_call->conn->dce_ctx->lp_ctx), dce_call->event_ctx, dce_call->conn->dce_ctx->lp_ctx, &sctx);
if (!NT_STATUS_IS_OK(status)) {
@@ -124,9 +125,10 @@ NTSTATUS srvsvc_create_ntvfs_context(struct dcesrv_call_state *dce_call,
NT_STATUS_HAVE_NO_MEMORY(ntvfs_req);
/* Invoke NTVFS connection hook */
- /* FIXME: Here is the right parameter missing!
- * status = ntvfs_connect(ntvfs_req, <TODO>); */
- status = NT_STATUS_UNSUCCESSFUL; /* return this for now */
+ tcon.tcon.level = RAW_TCON_TCON;
+ ZERO_STRUCT(tcon.tcon.in);
+ tcon.tcon.in.service = share;
+ status = ntvfs_connect(ntvfs_req, &tcon);
if (!NT_STATUS_IS_OK(status)) {
DEBUG(0,("srvsvc_create_ntvfs_context: NTVFS ntvfs_connect() failed!\n"));
return status;