summaryrefslogtreecommitdiffstats
path: root/fortran/src/H5Lf.c
diff options
context:
space:
mode:
authorScot Breitenfeld <brtnfld@hdfgroup.org>2015-03-23 21:23:39 (GMT)
committerScot Breitenfeld <brtnfld@hdfgroup.org>2015-03-23 21:23:39 (GMT)
commitce632854c3d542a22018221be1ec47cdad0affe2 (patch)
tree29b27353a506fe871196a1bad0bc01077ba8e934 /fortran/src/H5Lf.c
parent9630bfd9749c6a8f470325bb762e64835c3192e9 (diff)
downloadhdf5-ce632854c3d542a22018221be1ec47cdad0affe2.zip
hdf5-ce632854c3d542a22018221be1ec47cdad0affe2.tar.gz
hdf5-ce632854c3d542a22018221be1ec47cdad0affe2.tar.bz2
[svn-r26547] Merged changes from the trunk into the branch:
svn merge -r26029:26536 https://svn.hdfgroup.uiuc.edu/hdf5/trunk/fortran Tested: h5committest
Diffstat (limited to 'fortran/src/H5Lf.c')
-rw-r--r--fortran/src/H5Lf.c15
1 files changed, 9 insertions, 6 deletions
diff --git a/fortran/src/H5Lf.c b/fortran/src/H5Lf.c
index 7efa10a..6523ab4 100644
--- a/fortran/src/H5Lf.c
+++ b/fortran/src/H5Lf.c
@@ -677,9 +677,9 @@ done:
/****if* H5Lf/h5lget_name_by_idx_c
* NAME
- * h5lget_name_by_idx_c
+ * h5lget_name_by_idx_c
* PURPOSE
- * Call H5Lget_name_by_idx
+ * Call H5Lget_name_by_idx
* INPUTS
*
* loc_id - File or group identifier specifying location of subject group
@@ -694,10 +694,10 @@ done:
* name - Buffer in which link value is returned
* size - The size of the link name on success
* RETURNS
- * 0 on success, -1 on failure
+ * 0 on success, -1 on failure
* AUTHOR
* M. Scot Breitenfeld
- * March 10, 2008
+ * March 10, 2008
* SOURCE
*/
int_f
@@ -706,9 +706,10 @@ nh5lget_name_by_idx_c(hid_t_f *loc_id, _fcd group_name, size_t_f *group_namelen,
size_t_f *size, _fcd name, hid_t_f *lapl_id)
/******/
{
- char *c_group_name = NULL; /* Buffer to hold C string */
+ char *c_group_name = NULL; /* Buffer to hold C string */
char *c_name = NULL; /* Buffer to hold C string */
size_t c_size;
+ ssize_t c_size_link;
int_f ret_value = 0; /* Return value */
/*
@@ -725,10 +726,12 @@ nh5lget_name_by_idx_c(hid_t_f *loc_id, _fcd group_name, size_t_f *group_namelen,
if(NULL == (c_name = (char *)HDmalloc(c_size)))
HGOTO_DONE(FAIL)
- if((*size = (size_t_f)H5Lget_name_by_idx((hid_t)*loc_id, c_group_name, (H5_index_t)*index_field,
+ if((c_size_link = H5Lget_name_by_idx((hid_t)*loc_id, c_group_name, (H5_index_t)*index_field,
(H5_iter_order_t)*order, (hsize_t)*n,c_name, c_size, (hid_t)*lapl_id)) < 0)
HGOTO_DONE(FAIL)
+ *size = (size_t_f)c_size_link;
+
/*
* Convert C name to FORTRAN and place it in the given buffer
*/