On Wed, 28 Oct 2020 11:10:33 GMT, Daniel Fuchs <dfu...@openjdk.org> wrote:

>> Igor Ignatyev has updated the pull request incrementally with three 
>> additional commits since the last revision:
>> 
>>  - remove \n from MDTM response before parsing
>>  - added leading 0 to the test
>>  - use DateTimeFormatter instead of SimpleDateFormat
>
> src/java.base/share/classes/sun/net/ftp/impl/FtpClient.java line 1770:
> 
>> 1768:         try {
>> 1769:             var d = LocalDateTime.parse(s, RFC3659_DATETIME_FORMAT);
>> 1770:             result = 
>> Date.from(d.atZone(ZoneOffset.systemDefault()).toInstant());
> 
> Should this be ZoneOffset.UTC rather than System default? I thought the date 
> returned by the server were supposed to be in GMT.

ZoneOffset.UTC should return GMT as was the case with SimpleDateFormat before 
the changes.

-------------

PR: https://git.openjdk.java.net/jdk/pull/867

Reply via email to