I'm using the 'mirror' command to only upload modified files to the FTP server.

The server has an EST timezone.

Whenever I run the mirror command, all the files I've modified in the
last 5 hours are being re-uploaded.

It turns out that the timezone is taken into account when parsing the
UNIX-format ls output, but then the precision is only 30 seconds and
some code in NetAccess.cc decides that since file->date.ts_prec>0 &&
can_get_prec_time, we need to get a more precise version of the remote
timestamp.

This ends up using Ftp::ConvertFtpDate() in ftpclass.cc, which ignores
the timezone, instead doing: return mktime_from_utc(&tm);

It looks like we need some way of taking the timezone into account
when convering FTP dates in ftpclass.cc.  Replacing the
mktime_from_utc() in ftpclass.cc with:
  return mktime_from_tz(&tm, "EST");
fixes the problem for me, but isn't a particularly general fix...

Chris.

Reply via email to