From 787b0536b7a8d3b13bcb3b0f1d8f7ef7d99f4561 Mon Sep 17 00:00:00 2001 From: Stefan Metzmacher Date: Mon, 1 Dec 2008 13:52:28 -0800 Subject: s3:smbd: only try and fallback to open a directory if it's not a stream open metze --- source3/smbd/open.c | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'source3') diff --git a/source3/smbd/open.c b/source3/smbd/open.c index a8cc5c9118..420a65b562 100644 --- a/source3/smbd/open.c +++ b/source3/smbd/open.c @@ -2927,6 +2927,13 @@ NTSTATUS create_file_unixpath(connection_struct *conn, if (NT_STATUS_EQUAL(status, NT_STATUS_FILE_IS_A_DIRECTORY)) { + /* A stream open never opens a directory */ + + if (base_fsp) { + status = NT_STATUS_FILE_IS_A_DIRECTORY; + goto fail; + } + /* * Fail the open if it was explicitly a non-directory * file. -- cgit