mirror of
https://github.com/Alfresco/alfresco-community-repo.git
synced 2025-07-24 17:32:48 +00:00
Big honkin' merge from head. Sheesh!
git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/BRANCHES/WCM-DEV2/root@3617 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
@@ -568,6 +568,22 @@ public class FTPDataSession extends SrvSession implements Runnable
|
||||
netFile = disk.openFile( this, tree, params);
|
||||
}
|
||||
|
||||
// Commit any current transaction
|
||||
|
||||
try
|
||||
{
|
||||
// Commit or rollback the transaction
|
||||
|
||||
endTransaction();
|
||||
}
|
||||
catch ( Exception ex)
|
||||
{
|
||||
// Debug
|
||||
|
||||
if ( logger.isDebugEnabled())
|
||||
logger.debug("Error committing transaction", ex);
|
||||
}
|
||||
|
||||
// Check if the file has been opened
|
||||
|
||||
if (netFile == null)
|
||||
@@ -776,6 +792,22 @@ public class FTPDataSession extends SrvSession implements Runnable
|
||||
netFile = disk.createFile(this, tree, params);
|
||||
}
|
||||
|
||||
// Commit any current transaction
|
||||
|
||||
try
|
||||
{
|
||||
// Commit or rollback the transaction
|
||||
|
||||
endTransaction();
|
||||
}
|
||||
catch ( Exception ex)
|
||||
{
|
||||
// Debug
|
||||
|
||||
if ( logger.isDebugEnabled())
|
||||
logger.debug("Error committing transaction", ex);
|
||||
}
|
||||
|
||||
// Notify change listeners that a new file has been created
|
||||
|
||||
DiskDeviceContext diskCtx = (DiskDeviceContext) tree.getContext();
|
||||
|
@@ -50,10 +50,6 @@ public class FTPNetworkServer extends NetworkFileServer implements Runnable
|
||||
// Session Thread group
|
||||
private static final ThreadGroup THREAD_GROUP_SESSION = new ThreadGroup("FTP_SESSION_GROUP");
|
||||
|
||||
// Server version
|
||||
|
||||
private static final String ServerVersion = "3.5.0";
|
||||
|
||||
// Listen backlog for the server socket
|
||||
|
||||
protected static final int LISTEN_BACKLOG = 10;
|
||||
@@ -100,10 +96,6 @@ public class FTPNetworkServer extends NetworkFileServer implements Runnable
|
||||
{
|
||||
super("FTP", config);
|
||||
|
||||
// Set the server version
|
||||
|
||||
setVersion(ServerVersion);
|
||||
|
||||
// Allocate the session lists
|
||||
|
||||
m_sessions = new FTPSessionList();
|
||||
@@ -365,7 +357,6 @@ public class FTPNetworkServer extends NetworkFileServer implements Runnable
|
||||
if (logger.isDebugEnabled() && hasDebug())
|
||||
{
|
||||
logger.debug("FTP Server starting on port " + getPort());
|
||||
logger.debug("Version " + isVersion());
|
||||
}
|
||||
|
||||
// Create a server socket to listen for incoming FTP session requests
|
||||
|
@@ -137,7 +137,7 @@ public class FTPSrvSession extends SrvSession implements Runnable
|
||||
|
||||
// Flag to control whether data transfers use a seperate thread
|
||||
|
||||
private static boolean UseThreadedDataTransfer = true;
|
||||
private static boolean UseThreadedDataTransfer = false;
|
||||
|
||||
// Session socket
|
||||
|
||||
@@ -1839,7 +1839,23 @@ public class FTPSrvSession extends SrvSession implements Runnable
|
||||
|
||||
netFile = disk.openFile(this, tree, params);
|
||||
}
|
||||
|
||||
|
||||
// Commit any current transaction
|
||||
|
||||
try
|
||||
{
|
||||
// Commit or rollback the transaction
|
||||
|
||||
endTransaction();
|
||||
}
|
||||
catch ( Exception ex)
|
||||
{
|
||||
// Debug
|
||||
|
||||
if ( logger.isDebugEnabled())
|
||||
logger.debug("Error committing transaction", ex);
|
||||
}
|
||||
|
||||
// Check if the file has been opened
|
||||
|
||||
if (netFile == null)
|
||||
@@ -1898,7 +1914,7 @@ public class FTPSrvSession extends SrvSession implements Runnable
|
||||
m_dataSess = null;
|
||||
|
||||
// Close the network file
|
||||
|
||||
|
||||
disk.closeFile(this, tree, netFile);
|
||||
netFile = null;
|
||||
|
||||
@@ -2078,6 +2094,22 @@ public class FTPSrvSession extends SrvSession implements Runnable
|
||||
netFile = disk.createFile(this, tree, params);
|
||||
}
|
||||
|
||||
// Commit any current transaction
|
||||
|
||||
try
|
||||
{
|
||||
// Commit or rollback the transaction
|
||||
|
||||
endTransaction();
|
||||
}
|
||||
catch ( Exception ex)
|
||||
{
|
||||
// Debug
|
||||
|
||||
if ( logger.isDebugEnabled())
|
||||
logger.debug("Error committing transaction", ex);
|
||||
}
|
||||
|
||||
// Notify change listeners that a new file has been created
|
||||
|
||||
DiskDeviceContext diskCtx = (DiskDeviceContext) tree.getContext();
|
||||
|
Reference in New Issue
Block a user