Skip to content

Commit ca08047

Browse files
HDFS-17729. Inconsistent mtime in the results of -stat and -ls command due to different TimeZone. (#7405) Contributed by hfutatzhanghb.
Signed-off-by: Shilun Fan <slfan1989@apache.org>
1 parent 0dd9bf8 commit ca08047

File tree

1 file changed

+0
-2
lines changed
  • hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/fs/shell

1 file changed

+0
-2
lines changed

hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/fs/shell/Stat.java

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,6 @@
2222
import java.text.SimpleDateFormat;
2323
import java.util.Date;
2424
import java.util.LinkedList;
25-
import java.util.TimeZone;
2625

2726
import org.apache.hadoop.classification.InterfaceAudience;
2827
import org.apache.hadoop.classification.InterfaceStability;
@@ -73,7 +72,6 @@ public static void registerCommands(CommandFactory factory) {
7372
protected final SimpleDateFormat timeFmt;
7473
{
7574
timeFmt = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
76-
timeFmt.setTimeZone(TimeZone.getTimeZone("UTC"));
7775
}
7876

7977
// default format string

0 commit comments

Comments
 (0)