FS#1611 - Player creates files with illegal dates

Attached to Project: Rockbox
Opened by Barry McIntosh (combthins) - Wednesday, 13 August 2003, 12:21 GMT
Last edited by Daniel Stenberg (bagder) - Friday, 05 December 2003, 09:46 GMT
Task Type Bugs
Category Drivers
Status Closed
Assigned To No-one
Operating System
Severity Low
Priority Normal
Reported Version
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 0
Private No


New files created on Player (not Recorder or FM), where
there is no RTC, are created with an illegal write date.
New files are created with modified, created, and
accessed dates set to zero. This is not a valid date as
the day and month fields are 1 based. FAT permits the
create date and the last accessed date to be zero,
indicating that they are not supported, but requires that
write date and time must be supported.

Also, Player does not update the modified date when file
is modified.

Symptoms are that some disk synchronisation software
cannot properly synchronise files between PC and Player
(and may fail leaving files partly synchronised if not very

I suggest that on file creation, Player sets dates to a
known date (e.g. date of firmware build - similar to how
version is set in makefiles, but 1 Jan 1980 would be a
simpler option). On file modification the date/time
should be changed from current value. An increment of
a little over an hour would be good (e.g. 1hr 10mins) as
some synchronisation software deliberately ignores small
changes in file times.
This task depends upon

Closed by  Daniel Stenberg (bagder)
Friday, 05 December 2003, 09:46 GMT
Reason for closing:  Fixed
Comment by Barry McIntosh (combthins) - Tuesday, 19 August 2003, 21:18 GMT

I've submitted patch 791531 which addresses this bug.
Comment by Linus Nielsen Feltzing (linusnielsen) - Monday, 03 November 2003, 01:00 GMT

This is fixed in CVS.