Hi,
 
i found a bug in the date command.
date returns wrong year in the first calendar week if used with "1 weeks
ago"
 
unfortunatly this only reproduces, if the system date is set to somewhere in
the first week of the year.
The bug reproduces on cygwin and redhat linux 9 (all I got to test).
 
See session transcript below...
 
Can you inform me of the status of this bug?
 
Regards 
 
Robert
 
Session transcript:
 
[EMAIL PROTECTED] date-bug]$ date
Sun Jan  9 00:04:04 CET 2005
[EMAIL PROTECTED] date-bug]$ date +%Y-KW%V
# What date is now?
2005-KW01
[EMAIL PROTECTED] date-bug]$ date +%Y-KW%V -d "Tue Jan  4 23:56:12 CET 2005 1
weeks ago" # This is right
2004-KW53
[EMAIL PROTECTED] date-bug]$ date +%Y-KW%V -d " 1 weeks ago"
# OUCH, wrong year!
2005-KW53
[EMAIL PROTECTED] date-bug]$ date +%Y-KW%V -d " 2 weeks ago"
# and we are in sync again...
2004-KW52

_______________________________________________
Bug-coreutils mailing list
Bug-coreutils@gnu.org
http://lists.gnu.org/mailman/listinfo/bug-coreutils

Reply via email to