summaryrefslogtreecommitdiffstats
path: root/fortran/src
diff options
context:
space:
mode:
authorDana Robinson <derobins@hdfgroup.org>2020-08-04 01:43:19 (GMT)
committerDana Robinson <derobins@hdfgroup.org>2020-08-04 01:43:19 (GMT)
commitb2c90cc84ec84f51233d69f5eb951d48ba20d37e (patch)
tree2299f730d8dca896a182b03267d9f760a8ca5467 /fortran/src
parentbd685b0e803e13a10243bd0e50fa01c5fceffc67 (diff)
downloadhdf5-b2c90cc84ec84f51233d69f5eb951d48ba20d37e.zip
hdf5-b2c90cc84ec84f51233d69f5eb951d48ba20d37e.tar.gz
hdf5-b2c90cc84ec84f51233d69f5eb951d48ba20d37e.tar.bz2
Updated the file locking Fortran property list wrappers and added
a test.
Diffstat (limited to 'fortran/src')
-rw-r--r--fortran/src/H5Pf.c77
-rw-r--r--fortran/src/H5Pff.F9016
-rw-r--r--fortran/src/H5f90proto.h2
3 files changed, 8 insertions, 87 deletions
diff --git a/fortran/src/H5Pf.c b/fortran/src/H5Pf.c
index 9816d7b..7cb3db8 100644
--- a/fortran/src/H5Pf.c
+++ b/fortran/src/H5Pf.c
@@ -5241,83 +5241,6 @@ h5pget_file_image_c(hid_t_f *fapl_id, void **buf_ptr, size_t_f *buf_len_ptr)
return ret_value;
}
-/****if* H5Pf/h5pset_file_locking_c
- * NAME
- * h5pset_file_locking_c
- * PURPOSE
- * Call H5Pset_file_locking to set file locking properties.
- * INPUTS
- * prp_id - file access property list identifier
- * use_file_locking - TRUE/FALSE flag
- * ignore_disabled_file_locking - TRUE/FALSE flag
- * RETURNS
- * 0 on success, -1 on failure
- * AUTHOR
- * Dana Robinson
- * Summer 2020
- * SOURCE
-*/
-int_f
-h5pset_file_locking_c(hid_t_f *prp_id, int_f *use_file_locking, int_f *ignore_disabled_file_locking)
-/******/
-{
- int ret_value = 0;
- hid_t c_prp_id = H5I_INVALID_HID;
- herr_t status;
- hbool_t c_use_flag = 1;
- hbool_t c_ignore_flag = 1;
-
- if (*use_file_locking == 0) c_use_flag = 0;
- if (*ignore_disabled_file_locking == 0) c_ignore_flag = 1;
-
- c_prp_id = (hid_t)*prp_id;
-
- status = H5Pset_file_locking(c_prp_id, c_use_flag, c_ignore_flag);
-
- if ( status < 0 ) ret_value = -1;
-
- return ret_value;
-}
-
-
-/****if* H5Pf/h5pget_file_locking_c
- * NAME
- * h5pget_file_locking_c
- * PURPOSE
- * Call H5Pget_file_locking to get file locking properties.
- * INPUTS
- * prp_id - file access property list identifier
- * use_file_locking - TRUE/FALSE flag
- * ignore_disabled_file_locking - TRUE/FALSE flag
- * RETURNS
- * 0 on success, -1 on failure
- * AUTHOR
- * Dana Robinson
- * Summer 2020
- * SOURCE
-*/
-int_f
-h5pget_file_locking_c(hid_t_f *prp_id, int_f *use_file_locking, int_f *ignore_disabled_file_locking)
-/******/
-{
- int ret_value = 0;
- hid_t c_prp_id = H5I_INVALID_HID;
- hbool_t c_use_flag = 1;
- hbool_t c_ignore_flag = 1;
- herr_t c_ret;
-
- c_prp_id = (hid_t)*prp_id;
-
- c_ret = H5Pget_file_locking(c_prp_id, &c_use_flag, &c_ignore_flag);
-
- if ( c_ret < 0 ) ret_value = -1;
-
- *use_file_locking = (int_f)c_use_flag;
- *ignore_disabled_file_locking = (int_f)c_ignore_flag;
-
- return ret_value;
-}
-
#ifdef H5_HAVE_PARALLEL
/****if* H5Pf/h5pset_fapl_mpio_c
* NAME
diff --git a/fortran/src/H5Pff.F90 b/fortran/src/H5Pff.F90
index 40c4e95..38e3aac 100644
--- a/fortran/src/H5Pff.F90
+++ b/fortran/src/H5Pff.F90
@@ -8298,16 +8298,16 @@ END SUBROUTINE h5pget_virtual_dsetname_f
LOGICAL(C_BOOL) :: c_ignore_flag
INTERFACE
- INTEGER FUNCTION h5pget_file_locking_c(fapl_id, use_file_locking, ignore_disabled_locks) BIND(C, NAME='H5Pget_file_locking')
+ INTEGER FUNCTION h5pget_file_locking(fapl_id, use_file_locking, ignore_disabled_locks) BIND(C, NAME='H5Pget_file_locking')
IMPORT :: HID_T, C_BOOL
IMPLICIT NONE
INTEGER(HID_T), INTENT(IN), VALUE :: fapl_id
LOGICAL(C_BOOL), INTENT(OUT) :: use_file_locking
LOGICAL(C_BOOL), INTENT(OUT) :: ignore_disabled_locks
- END FUNCTION h5pget_file_locking_c
+ END FUNCTION h5pget_file_locking
END INTERFACE
- hdferr = INT(h5pget_file_locking_c(fapl_id, c_use_flag, c_ignore_flag))
+ hdferr = INT(h5pget_file_locking(fapl_id, c_use_flag, c_ignore_flag))
! Transfer value of C C_BOOL type to Fortran LOGICAL
use_file_locking = c_use_flag
@@ -8348,20 +8348,20 @@ END SUBROUTINE h5pget_virtual_dsetname_f
LOGICAL(C_BOOL) :: c_ignore_flag
INTERFACE
- INTEGER FUNCTION h5pset_file_locking_c(fapl_id, use_file_locking, ignore_disabled_locks) BIND(C, NAME='H5Pset_file_locking')
+ INTEGER FUNCTION h5pset_file_locking(fapl_id, use_file_locking, ignore_disabled_locks) BIND(C, NAME='H5Pset_file_locking')
IMPORT :: HID_T, C_BOOL
IMPLICIT NONE
INTEGER(HID_T), INTENT(IN), VALUE :: fapl_id
- LOGICAL(C_BOOL), INTENT(IN) :: use_file_locking
- LOGICAL(C_BOOL), INTENT(IN) :: ignore_disabled_locks
- END FUNCTION h5pset_file_locking_c
+ LOGICAL(C_BOOL), INTENT(IN), VALUE :: use_file_locking
+ LOGICAL(C_BOOL), INTENT(IN), VALUE :: ignore_disabled_locks
+ END FUNCTION h5pset_file_locking
END INTERFACE
! Transfer value of Fortran LOGICAL to C C_BOOL type
c_use_flag = use_file_locking
c_ignore_flag = ignore_disabled_locks
- hdferr = INT(h5pset_file_locking_c(fapl_id, c_use_flag, c_ignore_flag))
+ hdferr = INT(h5pset_file_locking(fapl_id, c_use_flag, c_ignore_flag))
END SUBROUTINE h5pset_file_locking_f
diff --git a/fortran/src/H5f90proto.h b/fortran/src/H5f90proto.h
index 56a685e..695efcd 100644
--- a/fortran/src/H5f90proto.h
+++ b/fortran/src/H5f90proto.h
@@ -481,8 +481,6 @@ H5_FCDLL int_f h5pset_nlinks_c(hid_t_f *lapl_id, size_t_f *nlinks);
H5_FCDLL int_f h5pget_nlinks_c(hid_t_f *lapl_id, size_t_f *nlinks);
H5_FCDLL int_f h5pset_chunk_cache_c(hid_t_f *dapl_id, size_t_f *rdcc_nslots, size_t_f *rdcc_nbytes, real_f *rdcc_w0);
H5_FCDLL int_f h5pget_chunk_cache_c(hid_t_f *dapl_id, size_t_f *rdcc_nslots, size_t_f *rdcc_nbytes, real_f *rdcc_w0);
-H5_FCDLL int_f h5pset_file_locking_c(hid_t_f *prp_id, int_f *use_file_locking, int_f *ignore_disabled_file_locking);
-H5_FCDLL int_f h5pget_file_locking_c(hid_t_f *prp_id, int_f *use_file_locking, int_f *ignore_disabled_file_locking);
#ifdef H5_HAVE_PARALLEL
H5_FCDLL int_f h5pget_mpio_actual_io_mode_c(hid_t_f *dxpl_id, int_f *actual_io_mode);
H5_FCDLL int_f h5pget_fapl_mpio_c(hid_t_f *prp_id, int_f* comm, int_f* info);