diff options
author | Bill Wendling <wendling@ncsa.uiuc.edu> | 2001-06-19 21:49:01 (GMT) |
---|---|---|
committer | Bill Wendling <wendling@ncsa.uiuc.edu> | 2001-06-19 21:49:01 (GMT) |
commit | 1fdcafdc893c22fd61b85b22c4b53c76a9090fd1 (patch) | |
tree | 5593a43ac8c9e363bdb31b45b7f159da9e42a4e1 /src/H5Omtime.c | |
parent | 09676ded1f6e9480e5154c8dcdf6a0226755d28b (diff) | |
download | hdf5-1fdcafdc893c22fd61b85b22c4b53c76a9090fd1.zip hdf5-1fdcafdc893c22fd61b85b22c4b53c76a9090fd1.tar.gz hdf5-1fdcafdc893c22fd61b85b22c4b53c76a9090fd1.tar.bz2 |
[svn-r4022] Purpose:
Code Cleanup
Description:
Changed POSIX function calls to the HD* way of doing things. Checked
with checkposix and tested on Linux.
Platforms tested:
Linux
Diffstat (limited to 'src/H5Omtime.c')
-rw-r--r-- | src/H5Omtime.c | 36 |
1 files changed, 17 insertions, 19 deletions
diff --git a/src/H5Omtime.c b/src/H5Omtime.c index 316ce38..2069a59 100644 --- a/src/H5Omtime.c +++ b/src/H5Omtime.c @@ -129,35 +129,33 @@ H5O_mtime_decode(H5F_t UNUSED *f, const uint8_t *p, #elif defined(H5_HAVE_BSDGETTIMEOFDAY) && defined(H5_HAVE_STRUCT_TIMEZONE) /* Irix5.3 */ { - struct timezone tz; - if (BSDgettimeofday(NULL, &tz)<0) { - HRETURN_ERROR(H5E_OHDR, H5E_CANTINIT, NULL, - "unable to obtain local timezone information"); - } - the_time -= tz.tz_minuteswest*60 - (tm.tm_isdst?3600:0); + struct timezone tz; + if (HDBSDgettimeofday(NULL, &tz)<0) { + HRETURN_ERROR(H5E_OHDR, H5E_CANTINIT, NULL, + "unable to obtain local timezone information"); + } + the_time -= tz.tz_minuteswest * 60 - (tm.tm_isdst ? 3600 : 0); } #elif defined(H5_HAVE_GETTIMEOFDAY) && defined(H5_HAVE_STRUCT_TIMEZONE) { struct timezone tz; - if (gettimeofday(NULL, &tz)<0) { + + if (HDgettimeofday(NULL, &tz) < 0) { HRETURN_ERROR(H5E_OHDR, H5E_CANTINIT, NULL, "unable to obtain local timezone information"); } - the_time -= tz.tz_minuteswest*60 - (tm.tm_isdst?3600:0); + + the_time -= tz.tz_minuteswest * 60 - (tm.tm_isdst ? 3600 : 0); } #elif defined (WIN32) && !defined (__MWERKS__) - { - - struct timeb timebuffer; - long tz; - ftime( &timebuffer ); - - tz = timebuffer.timezone; - - the_time -=tz*60-3600*_daylight; + { + struct timeb timebuffer; + long tz; - -} + ftime(&timebuffer); + tz = timebuffer.timezone; + the_time -= tz * 60 - 3600 * _daylight; + } #else /* * The catch-all. If we can't convert a character string universal |