PR 9769
authorNick Clifton <nickc@redhat.com>
Wed, 21 Jan 2009 11:58:05 +0000 (11:58 +0000)
committerNick Clifton <nickc@redhat.com>
Wed, 21 Jan 2009 11:58:05 +0000 (11:58 +0000)
        * vmsutil.c (vms_file_stats_name): Remove use of unsupported
        tm_gmtoff field in struct tm.

bfd/ChangeLog
bfd/vmsutil.c

index 2876ce77d4907384297da10c6b881a4126ce8c3f..f6e97266f3ff600b8060b912bf1551cabde11108 100644 (file)
@@ -1,3 +1,9 @@
+2009-01-21  Nick Clifton  <nickc@redhat.com>
+
+       PR 9769
+       * vmsutil.c (vms_file_stats_name): Remove use of unsupported
+       tm_gmtoff field in struct tm.
+
 2009-01-21  Alan Modra  <amodra@bigpond.net.au>
 
        * elf32-spu.h (struct spu_elf_params): Add non_ia_text.
index 25cd8898743a5a2dc0e293f204cc56c8229aee10..83c4609df419d6e246be644609b41ba5eca64bd0 100644 (file)
@@ -238,7 +238,6 @@ vms_file_stats_name (const char *filename,
 #else
   struct stat buff;
   struct tm *ts;
-  long gmtoff;
 
   if ((stat (filename, &buff)) != 0)
      return 1;
@@ -246,8 +245,7 @@ vms_file_stats_name (const char *filename,
   if (cdt)
     {
       ts = localtime (&buff.st_mtime);
-      gmtoff = ts->tm_gmtoff;
-      *cdt = (long long) (((buff.st_mtim.tv_sec + gmtoff) * VMS_GRANULARITY_FACTOR)
+      *cdt = (long long) ((buff.st_mtim.tv_sec * VMS_GRANULARITY_FACTOR)
                           + (buff.st_mtim.tv_nsec / 100))
                          + VMS_EPOCH_OFFSET;
     }
This page took 0.027231 seconds and 4 git commands to generate.