Ignore:
Timestamp:
Jul 6, 2017, 9:53:56 AM (8 years ago)
Author:
Valery V. Sedletski
Message:
  • Fix skipping 2nd cluster on exFAT when cluster size is 128+ KB when reading and writing files.
  • Make FORMAT create FS'es with 128 KB or more clusters. Support the case with a very small (1kb or so) clusters, when the allocation bitmap uses many clusters, so they don't fit into one FAT sector.
  • Add support for adding timestamps for files created by CHKDSK.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • TabularUnified trunk/src/ufat32/win32.c

    r282 r289  
    378378void set_datetime(DIRENTRY *pDir)
    379379{
     380    // FAT12/FAT16/FAT32
    380381    SYSTEMTIME datetime;
    381382
     
    394395}
    395396
     397
     398void set_datetime1(DIRENTRY1 *pDir)
     399{
     400   // exFAT
     401   SYSTEMTIME datetime;
     402
     403   GetSystemTime(&datetime);
     404
     405   pDir->u.File.ulLastModifiedTimestp.year = datetime.wYear - 1980;
     406   pDir->u.File.ulLastModifiedTimestp.month = datetime.wMonth;
     407   pDir->u.File.ulLastModifiedTimestp.day = datetime.wDay;
     408   pDir->u.File.ulLastModifiedTimestp.hour = datetime.wHour;
     409   pDir->u.File.ulLastModifiedTimestp.minutes = datetime.wMinute;
     410   pDir->u.File.ulLastModifiedTimestp.seconds = datetime.wSecond / 2;
     411
     412   pDir->u.File.ulCreateTimestp = pDir->u.File.ulLastModifiedTimestp;
     413   pDir->u.File.ulLastAccessedTimestp = pDir->u.File.ulLastModifiedTimestp;
     414}
    396415
    397416char *get_error(USHORT rc)
Note: See TracChangeset for help on using the changeset viewer.