diff options
author | Andrew Tridgell <tridge@samba.org> | 1999-07-15 11:42:53 +0000 |
---|---|---|
committer | Andrew Tridgell <tridge@samba.org> | 1999-07-15 11:42:53 +0000 |
commit | 02518fd7725fe432a999b5076ffe42847b0d79bd (patch) | |
tree | 342477c201d4edbd4a3493e388afd9a606058974 | |
parent | 1016f838257db3458fb313201fefe6b5144420df (diff) | |
download | samba-02518fd7725fe432a999b5076ffe42847b0d79bd.tar.gz |
fix from matty for directory creation on read-only shares
-rw-r--r-- | source/smbd/open.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/source/smbd/open.c b/source/smbd/open.c index a28a0c348a3..01e1cebbb6b 100644 --- a/source/smbd/open.c +++ b/source/smbd/open.c @@ -1169,6 +1169,11 @@ int open_directory(files_struct *fsp,connection_struct *conn, * Try and create the directory. */ + if(conn->read_only) { + DEBUG(2,("open_directory: failing create on read-only share\n")); + return -1; + } + if(dos_mkdir(fname, unix_mode(conn,aDIR)) < 0) { DEBUG(0,("open_directory: unable to create %s. Error was %s\n", fname, strerror(errno) )); |