]> git.ipfire.org Git - thirdparty/samba.git/commitdiff
s3: Fix OneFS bug opening streams with truncating disposition
authorAravind Srinivasan <aravind.srinivasan@isilon.com>
Thu, 19 Feb 2009 02:26:39 +0000 (18:26 -0800)
committerSteven Danneman <steven.danneman@isilon.com>
Thu, 19 Feb 2009 04:50:05 +0000 (20:50 -0800)
Do not attempt to delete streams on a truncating open, if the name we're
opening is itself a stream

source3/modules/onefs_open.c

index 1f5f8551ffb0e1196c70841d4a9e4aaad6417f59..382ecc60a33e8393c8a2be2dcf83c25aa599e0aa 100644 (file)
@@ -1185,7 +1185,7 @@ NTSTATUS onefs_open_file_ntcreate(connection_struct *conn,
        SMB_ASSERT(lck != NULL);
 
        /* Delete streams if create_disposition requires it */
-       if (file_existed && clear_ads) {
+       if (file_existed && clear_ads && !is_ntfs_stream_name(fname)) {
                status = delete_all_streams(conn, fname);
                if (!NT_STATUS_IS_OK(status)) {
                        TALLOC_FREE(lck);