Merge V1.3 to HEAD (3045:3063)

svn merge svn://www.alfresco.org:3691/alfresco/BRANCHES/V1.3@3045 svn://www.alfresco.org:3691/alfresco/BRANCHES/V1.3@3063 .


git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@3340 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
Derek Hulley
2006-07-18 15:22:09 +00:00
parent a05f525a7d
commit dbffd532f7
9 changed files with 41 additions and 84 deletions

View File

@@ -6576,41 +6576,12 @@ public class NTProtocolHandler extends CoreProtocolHandler
return;
}
// Check if this is a buffer length check, if so the maximum returned data count will be
// zero
// Return an empty security descriptor
byte[] paramblk = new byte[4];
DataPacker.putIntelInt(0, paramblk, 0);
if (tbuf.getReturnDataLimit() == 0)
{
// Return the security descriptor length in the parameter block
byte[] paramblk = new byte[4];
DataPacker.putIntelInt(_sdEveryOne.length, paramblk, 0);
// Initialize the transaction reply
outPkt.initTransactReply(paramblk, paramblk.length, null, 0);
// Set a warning status to indicate the supplied data buffer was too small to return the
// security
// descriptor
outPkt.setLongErrorCode(SMBStatus.NTBufferTooSmall);
}
else
{
// Return the security descriptor length in the parameter block
byte[] paramblk = new byte[4];
DataPacker.putIntelInt(_sdEveryOne.length, paramblk, 0);
// Initialize the transaction reply. Return the fixed security descriptor that allows
// anyone to access the
// file/directory
outPkt.initTransactReply(paramblk, paramblk.length, _sdEveryOne, _sdEveryOne.length);
}
outPkt.initTransactReply(paramblk, paramblk.length, null, 0);
// Send back the response

View File

@@ -1344,7 +1344,7 @@ public class SMBSrvSession extends SrvSession implements Runnable
// We are using case sensitive pathnames and long file names
setDefaultFlags(0);
setDefaultFlags(SMBSrvPacket.FLG_CASELESS);
setDefaultFlags2(SMBSrvPacket.FLG2_LONGFILENAMES + SMBSrvPacket.FLG2_UNICODE);
// Access the authenticator for this server and determine if the server is in share or

View File

@@ -598,10 +598,8 @@ public class ContentDiskDriver implements DiskInterface, IOCtlInterface
{
// a valid use case
if (logger.isDebugEnabled())
{
logger.debug("Getting file information - File not found: \n" +
" path: " + path);
}
throw e;
}
catch (org.alfresco.repo.security.permissions.AccessDeniedException ex)
@@ -1449,7 +1447,8 @@ public class ContentDiskDriver implements DiskInterface, IOCtlInterface
try
{
// get the node
// Get the node
NodeRef nodeRef = getNodeForPath(tree, name);
if (nodeService.exists(nodeRef))
{
@@ -1602,8 +1601,11 @@ public class ContentDiskDriver implements DiskInterface, IOCtlInterface
// DEBUG
if ( logger.isDebugEnabled())
if ( logger.isDebugEnabled())
{
logger.debug("Cached rename state for " + oldName + ", state=" + fstate);
logger.debug(" new name " + newName + ", state=" + newState);
}
}
}
else

View File

@@ -20,7 +20,6 @@ import org.alfresco.filesys.locking.FileLock;
import org.alfresco.filesys.locking.FileLockList;
import org.alfresco.filesys.locking.LockConflictException;
import org.alfresco.filesys.locking.NotLockedException;
import org.alfresco.filesys.server.filesys.FileName;
import org.alfresco.filesys.server.filesys.FileOpenParams;
import org.alfresco.filesys.server.filesys.FileStatus;
import org.alfresco.filesys.smb.SharingMode;
@@ -587,35 +586,7 @@ public class FileState
*/
public final static String normalizePath(String path)
{
// Split the path into directories and file name, only uppercase the directories to
// normalize the path.
String normPath = path;
if (path.length() > 3)
{
// Split the path to seperate the folders/file name
int pos = path.lastIndexOf(FileName.DOS_SEPERATOR);
if (pos != -1)
{
// Get the path and file name parts, normalize the path
String pathPart = path.substring(0, pos).toUpperCase();
String namePart = path.substring(pos);
// Rebuild the path string
normPath = pathPart + namePart;
}
}
// Return the normalized path
return normPath;
return path.toUpperCase();
}
/**

View File

@@ -448,7 +448,7 @@ public class FileStateTable implements Runnable
// Dump the file state cache entries to the specified stream
if (m_stateTable.size() > 0)
logger.info("++ FileStateCache Entries:");
logger.debug("++ FileStateCache Entries:");
Enumeration enm = m_stateTable.keys();
long curTime = System.currentTimeMillis();
@@ -458,7 +458,7 @@ public class FileStateTable implements Runnable
String fname = (String) enm.nextElement();
FileState state = m_stateTable.get(fname);
logger.info(" ++ " + fname + "(" + state.getSecondsToExpire(curTime) + ") : " + state);
logger.debug(" ++ " + fname + "(" + state.getSecondsToExpire(curTime) + ") : " + state);
}
}
}