[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug in date --date="... sec"

From: Enke, Michael
Subject: bug in date --date="... sec"
Date: Mon, 23 Sep 2002 11:14:48 +0200

I guess I found a bug in date when converting seconds to readable date.
I perform the following command:

address@hidden:~ > date && date +%s
Mon Sep 23 11:04:44 CEST 2002

So 1032771884 is the number of seconds since 1970-01-01 00:00:00 UTC.

Now I want to convert back from seconds to readable date:

address@hidden:~ > date --date="1970-01-01 1032771884 sec"
Mon Sep 23 10:04:44 CEST 2002

The output should show: 11:04:44 and not 10:04:44 since seconds
are always from 00:00:00 UTC

If I call:

address@hidden:~ > date --date="1970-01-01 1032771884 sec UTC"
Mon Sep 23 12:04:44 CEST 2002

I also don't get 11:04:44

Dr. Michael Enke

reply via email to

[Prev in Thread] Current Thread [Next in Thread]