Skip to content

Commit

Permalink
Changed fatfs_dos_2_unix_time to function time zone independent sleut…
Browse files Browse the repository at this point in the history
  • Loading branch information
joachimmetz committed Sep 5, 2024
1 parent 18358cd commit 8519024
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions tsk/fs/fatfs_utils.c
Original file line number Diff line number Diff line change
Expand Up @@ -179,8 +179,11 @@ fatfs_dos_2_unix_time(uint16_t date, uint16_t time, uint8_t timetens)
* it out */
tm1.tm_isdst = -1;

ret = mktime(&tm1);

#if defined( _MSC_VER )
ret = _mkgmtime(&tm1);
#else
ret = timegm(&tm1);
#endif
if (ret < 0) {
if (tsk_verbose)
tsk_fprintf(stderr,
Expand Down

0 comments on commit 8519024

Please sign in to comment.