Ignore:
Timestamp:
May 27, 2009, 11:39:15 AM (16 years ago)
Author:
Herwig Bauernfeind
Message:

Update 3.2 branch to 3.2.9

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/samba-3.2.x/source/smbd/open.c

    r232 r233  
    11941194        bool posix_open = False;
    11951195        bool new_file_created = False;
     1196        bool clear_ads = false;
    11961197        struct file_id id;
    11971198        NTSTATUS fsp_open = NT_STATUS_ACCESS_DENIED;
     
    13261327                         * exist create. */
    13271328                        flags2 |= (O_CREAT | O_TRUNC);
     1329                        clear_ads = true;
    13281330                        break;
    13291331
     
    13321334                         * exist create. */
    13331335                        flags2 |= (O_CREAT | O_TRUNC);
     1336                        clear_ads = true;
    13341337                        break;
    13351338
     
    13561359                        }
    13571360                        flags2 |= O_TRUNC;
     1361                        clear_ads = true;
    13581362                        break;
    13591363
     
    17871791
    17881792        SMB_ASSERT(lck != NULL);
     1793
     1794        /* Delete streams if create_disposition requires it */
     1795        if (file_existed && clear_ads && !is_ntfs_stream_name(fname)) {
     1796                status = delete_all_streams(conn, fname);
     1797                if (!NT_STATUS_IS_OK(status)) {
     1798                        TALLOC_FREE(lck);
     1799                        fd_close(fsp);
     1800                        return status;
     1801                }
     1802        }
    17891803
    17901804        /* note that we ignore failure for the following. It is
Note: See TracChangeset for help on using the changeset viewer.