summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorderobins <dana.e.robinson@gmail.com>2016-11-11 19:16:24 (GMT)
committerderobins <dana.e.robinson@gmail.com>2016-11-11 19:16:24 (GMT)
commitbe0dfa3e22bcd1454215e2a348756bf21e749044 (patch)
tree6b32a73f0f45b607887787588504040fdbbcb91e /src
parentdd4f4e6f7641644cedeaae9214e4d8c39243d9ce (diff)
downloadhdf5-be0dfa3e22bcd1454215e2a348756bf21e749044.zip
hdf5-be0dfa3e22bcd1454215e2a348756bf21e749044.tar.gz
hdf5-be0dfa3e22bcd1454215e2a348756bf21e749044.tar.bz2
Moved Win32 variables to top of function in H5FDlog.c.
Diffstat (limited to 'src')
-rw-r--r--src/H5FDlog.c17
1 files changed, 9 insertions, 8 deletions
diff --git a/src/H5FDlog.c b/src/H5FDlog.c
index dae0e4a..9f5dfa5 100644
--- a/src/H5FDlog.c
+++ b/src/H5FDlog.c
@@ -1567,7 +1567,15 @@ static herr_t
H5FD_log_truncate(H5FD_t *_file, hid_t H5_ATTR_UNUSED dxpl_id, hbool_t H5_ATTR_UNUSED closing)
{
H5FD_log_t *file = (H5FD_log_t *)_file;
- herr_t ret_value = SUCCEED; /* Return value */
+#ifdef H5_HAVE_WIN32_API
+ LARGE_INTEGER li; /* 64-bit (union) integer for SetFilePointer() call */
+ DWORD dwPtrLow; /* Low-order pointer bits from SetFilePointer()
+ * Only used as an error code here.
+ */
+ DWORD dwError; /* DWORD error code from GetLastError() */
+ BOOL bError; /* Boolean error flag */
+#endif /* H5_HAVE_WIN32_API */
+herr_t ret_value = SUCCEED; /* Return value */
FUNC_ENTER_NOAPI_NOINIT
@@ -1584,13 +1592,6 @@ H5FD_log_truncate(H5FD_t *_file, hid_t H5_ATTR_UNUSED dxpl_id, hbool_t H5_ATTR_U
HDgettimeofday(&timeval_start, NULL);
#endif /* H5_HAVE_GETTIMEOFDAY */
#ifdef H5_HAVE_WIN32_API
- LARGE_INTEGER li; /* 64-bit (union) integer for SetFilePointer() call */
- DWORD dwPtrLow; /* Low-order pointer bits from SetFilePointer()
- * Only used as an error code here.
- */
- DWORD dwError; /* DWORD error code from GetLastError() */
- BOOL bError; /* Boolean error flag */
-
/* Windows uses this odd QuadPart union for 32/64-bit portability */
li.QuadPart = (__int64)file->eoa;