Yet another merge from head to WCM-DEV2.

git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/BRANCHES/WCM-DEV2/root@3774 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
Britt Park
2006-09-12 18:55:07 +00:00
parent e459c188f6
commit 39a18df7f2
65 changed files with 11344 additions and 8063 deletions

View File

@@ -41,10 +41,10 @@ public class FTPDate
* Pack a date string in Unix format The format is 'Mmm dd hh:mm' if the file is less than six
* months old, else the format is 'Mmm dd yyyy'.
*
* @param buf StringBuffer
* @param buf StringBuilder
* @param dt Date
*/
public final static void packUnixDate(StringBuffer buf, Date dt)
public final static void packUnixDate(StringBuilder buf, Date dt)
{
// Check if the date is valid

View File

@@ -1320,11 +1320,10 @@ public class FTPSrvSession extends SrvSession implements Runnable
// Output the file information to the client
StringBuffer str = new StringBuffer(256);
StringBuilder str = new StringBuilder(256);
for (FileInfo finfo : files)
{
// Build the output record
str.setLength(0);

View File

@@ -180,7 +180,7 @@ public class PassthruAuthenticator extends CifsAuthenticator implements SessionL
// using the session that has already been setup.
AuthenticateSession authSess = passDetails.getAuthenticateSession();
authSess.doSessionSetup(client.getUserName(), client.getANSIPassword(), client.getPassword());
authSess.doSessionSetup(client.getDomain(), client.getUserName(), null, client.getANSIPassword(), client.getPassword());
// Check if the user has been logged on as a guest

View File

@@ -113,6 +113,11 @@ public class CheckInOutDesktopAction extends DesktopAction {
}
catch (Exception ex)
{
// Dump the error
if ( logger.isErrorEnabled())
logger.error("Desktop action error", ex);
// Return an error status and message
response.setStatus(StsError, "Checkin failed for " + target.getTarget() + ", " + ex.getMessage());
@@ -122,6 +127,19 @@ public class CheckInOutDesktopAction extends DesktopAction {
{
try
{
// Check if the file is locked
if ( getNodeService().hasAspect( target.getNode(), ContentModel.ASPECT_LOCKABLE)) {
// Get the lock type
String lockTypeStr = (String) getNodeService().getProperty( target.getNode(), ContentModel.PROP_LOCK_TYPE);
if ( lockTypeStr != null) {
response.setStatus(StsError, "Checkout failed, file is locked");
return response;
}
}
// Check out the file
NodeRef workingCopyNode = getCheckInOutService().checkout( target.getNode());
@@ -149,6 +167,11 @@ public class CheckInOutDesktopAction extends DesktopAction {
}
catch (Exception ex)
{
// Dump the error
if ( logger.isErrorEnabled())
logger.error("Desktop action error", ex);
// Return an error status and message
response.setStatus(StsError, "Failed to checkout " + target.getTarget() + ", " + ex.getMessage());

View File

@@ -47,6 +47,6 @@ public class CmdLineDesktopAction extends DesktopAction {
// Return a URL in the status message
return new DesktopResponse(StsCommandLine, "C:\\Windows\\notepad.exe");
return new DesktopResponse(StsCommandLine, "%SystemRoot%\\notepad.exe");
}
}