ALF-11685 CIFS: Emacs editor leaves data (dates and filenames) in bad state

git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@32357 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
Mark Rogers
2011-11-28 16:39:18 +00:00
parent c6f4ac8b57
commit 54e823abdd

View File

@@ -1918,12 +1918,16 @@ public class ContentDiskDriver2 extends AlfrescoDiskDriver implements ExtendedD
{ {
throw new DirectoryNotEmptyException( name); throw new DirectoryNotEmptyException( name);
} }
}
}
if(info.isHidden())
{
if ( logger.isDebugEnabled()) if ( logger.isDebugEnabled())
{ {
logger.debug("Set deleteOnClose=true file=" + name); logger.debug("Set hidden attribute" + name);
}
} }
// Not yet implemented
} }
if( info.hasSetFlag(FileInfo.SetAllocationSize)) if( info.hasSetFlag(FileInfo.SetAllocationSize))
@@ -1943,17 +1947,17 @@ public class ContentDiskDriver2 extends AlfrescoDiskDriver implements ExtendedD
// The NTProtocolHandler sets the deleteOnClose in both // The NTProtocolHandler sets the deleteOnClose in both
// info and the NetworkFile - it's the one in NetworkFile that works. // info and the NetworkFile - it's the one in NetworkFile that works.
if ( info.hasSetFlag(FileInfo.SetCreationDate)) if ( info.hasSetFlag(FileInfo.SetCreationDate) && info.hasCreationDateTime())
{ {
// Set the creation date on the file/folder node // Set the creation date on the file/folder node
Date createDate = new Date( info.getCreationDateTime()); Date createDate = new Date(info.getCreationDateTime());
auditableProps.put(ContentModel.PROP_CREATED, createDate); auditableProps.put(ContentModel.PROP_CREATED, createDate);
if ( logger.isDebugEnabled()) if ( logger.isDebugEnabled())
{ {
logger.debug("Set creation date" + name + ", " + createDate); logger.debug("Set creation date" + name + ", " + createDate);
} }
} }
if ( info.hasSetFlag(FileInfo.SetModifyDate)) if ( info.hasSetFlag(FileInfo.SetModifyDate) && info.hasModifyDateTime())
{ {
// Set the modification date on the file/folder node // Set the modification date on the file/folder node
Date modifyDate = new Date( info.getModifyDateTime()); Date modifyDate = new Date( info.getModifyDateTime());