summaryrefslogtreecommitdiffstats
path: root/src/H5FDsec2.c
diff options
context:
space:
mode:
authorElena Pourmal <epourmal@hdfgroup.org>2006-03-09 21:30:19 (GMT)
committerElena Pourmal <epourmal@hdfgroup.org>2006-03-09 21:30:19 (GMT)
commit3f791d1b063dda2c36646c61bfde50a988a90f79 (patch)
tree7f605a45c6f4d04dad9d5867c77e0fb327151845 /src/H5FDsec2.c
parent00dd94b69bf11346bc4e8caf537b7a6ad43f7a6f (diff)
downloadhdf5-3f791d1b063dda2c36646c61bfde50a988a90f79.zip
hdf5-3f791d1b063dda2c36646c61bfde50a988a90f79.tar.gz
hdf5-3f791d1b063dda2c36646c61bfde50a988a90f79.tar.bz2
[svn-r12054] Purpose: VMS port
Description: Made small changes to sec2 driver to reflect that VMS systems ino_t is 1dim array of size 3; all changes are marked with H5_VMS variable. Defined HDremove macro for VMS to remove multiple versions of the files. Solution: Platforms tested: heping, VMS server Misc. update:
Diffstat (limited to 'src/H5FDsec2.c')
-rw-r--r--src/H5FDsec2.c17
1 files changed, 17 insertions, 0 deletions
diff --git a/src/H5FDsec2.c b/src/H5FDsec2.c
index f45deb1..943f615 100644
--- a/src/H5FDsec2.c
+++ b/src/H5FDsec2.c
@@ -71,7 +71,11 @@ typedef struct H5FD_sec2_t {
* identify a file.
*/
dev_t device; /*file device number */
+#ifdef H5_VMS
+ ino_t inode[3]; /*file i-node number */
+#else
ino_t inode; /*file i-node number */
+#endif /*H5_VMS*/
#else
/*
* On WIN32 the low-order word of a unique identifier associated with the
@@ -382,7 +386,14 @@ H5FD_sec2_open(const char *name, unsigned flags, hid_t UNUSED fapl_id,
file->fileindexlo = fileinfo.nFileIndexLow;
#else
file->device = sb.st_dev;
+#ifdef H5_VMS
+ file->inode[0] = sb.st_ino[0];
+ file->inode[1] = sb.st_ino[1];
+ file->inode[2] = sb.st_ino[2];
+#else
file->inode = sb.st_ino;
+#endif /*H5_VMS*/
+
#endif
/* Set return value */
@@ -479,8 +490,14 @@ H5FD_sec2_cmp(const H5FD_t *_f1, const H5FD_t *_f2)
if(HDmemcmp(&(f1->device),&(f2->device),sizeof(dev_t))>0) HGOTO_DONE(1)
#endif /* H5_DEV_T_IS_SCALAR */
+#ifndef H5_VMS
if (f1->inode < f2->inode) HGOTO_DONE(-1)
if (f1->inode > f2->inode) HGOTO_DONE(1)
+#else
+ if(HDmemcmp(&(f1->inode),&(f2->inode),3*sizeof(ino_t))<0) HGOTO_DONE(-1)
+ if(HDmemcmp(&(f1->inode),&(f2->inode),3*sizeof(ino_t))>0) HGOTO_DONE(1)
+#endif /*H5_VMS*/
+
#endif
done: