You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@commons.apache.org by se...@apache.org on 2008/04/07 02:47:52 UTC
svn commit: r645337 -
/commons/proper/net/trunk/src/java/org/apache/commons/net/ftp/parser/FTPTimestampParserImpl.java
Author: sebb
Date: Sun Apr 6 17:47:49 2008
New Revision: 645337
URL: http://svn.apache.org/viewvc?rev=645337&view=rev
Log:
Take a copy of the server timestamp, because we may need to change it
Modified:
commons/proper/net/trunk/src/java/org/apache/commons/net/ftp/parser/FTPTimestampParserImpl.java
Modified: commons/proper/net/trunk/src/java/org/apache/commons/net/ftp/parser/FTPTimestampParserImpl.java
URL: http://svn.apache.org/viewvc/commons/proper/net/trunk/src/java/org/apache/commons/net/ftp/parser/FTPTimestampParserImpl.java?rev=645337&r1=645336&r2=645337&view=diff
==============================================================================
--- commons/proper/net/trunk/src/java/org/apache/commons/net/ftp/parser/FTPTimestampParserImpl.java (original)
+++ commons/proper/net/trunk/src/java/org/apache/commons/net/ftp/parser/FTPTimestampParserImpl.java Sun Apr 6 17:47:49 2008
@@ -88,9 +88,10 @@
*
* @see org.apache.commons.net.ftp.parser.FTPTimestampParser#parseTimestamp(java.lang.String)
* @param timestampStr The timestamp to be parsed
- * @param now The current time
+ * @param serverTime The current time for the server
*/
- public Calendar parseTimestamp(String timestampStr, Calendar now) throws ParseException {
+ public Calendar parseTimestamp(String timestampStr, Calendar serverTime) throws ParseException {
+ Calendar now = (Calendar) serverTime.clone();// Copy this, because we may change it
now.setTimeZone(this.getServerTimeZone());
Calendar working = (Calendar) now.clone();;
working.setTimeZone(getServerTimeZone());