summaryrefslogtreecommitdiff
path: root/source4/ntvfs/print
diff options
context:
space:
mode:
authorStefan Metzmacher <metze@samba.org>2005-02-22 11:33:33 +0000
committerGerald (Jerry) Carter <jerry@samba.org>2007-10-10 13:10:51 -0500
commit90428a44a91d0a97769ba6c2d8459c35a9e96b12 (patch)
tree6dafe20d421385fb0b9290147be45a71007bc463 /source4/ntvfs/print
parent1bee0173ece788627017288e5d03bc28b4c04402 (diff)
downloadsamba-90428a44a91d0a97769ba6c2d8459c35a9e96b12.tar.gz
samba-90428a44a91d0a97769ba6c2d8459c35a9e96b12.tar.bz2
samba-90428a44a91d0a97769ba6c2d8459c35a9e96b12.zip
r5500: ntvfs modules that are the final backend needs to set the
dev and fs types this prevents the main smbsrv code from crashing when someone does a tree connect on a print share metze (This used to be commit e8b081d5d10ef617eaed88fd05990e7753a85b99)
Diffstat (limited to 'source4/ntvfs/print')
-rw-r--r--source4/ntvfs/print/vfs_print.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/source4/ntvfs/print/vfs_print.c b/source4/ntvfs/print/vfs_print.c
index c62357c949..c04cf76f33 100644
--- a/source4/ntvfs/print/vfs_print.c
+++ b/source4/ntvfs/print/vfs_print.c
@@ -34,6 +34,14 @@
static NTSTATUS print_connect(struct ntvfs_module_context *ntvfs,
struct smbsrv_request *req, const char *sharename)
{
+ struct smbsrv_tcon *tcon = req->tcon;
+
+ tcon->fs_type = talloc_strdup(tcon, "NTFS");
+ NT_STATUS_HAVE_NO_MEMORY(tcon->fs_type);
+
+ tcon->dev_type = talloc_strdup(tcon, "LPT1:");
+ NT_STATUS_HAVE_NO_MEMORY(tcon->dev_type);
+
return NT_STATUS_OK;
}