summaryrefslogtreecommitdiffstats
path: root/c++/src
diff options
context:
space:
mode:
authorRaymond Lu <songyulu@hdfgroup.org>2008-09-26 21:50:36 (GMT)
committerRaymond Lu <songyulu@hdfgroup.org>2008-09-26 21:50:36 (GMT)
commitf11d4727554c852a9deff20ae73971bd73e8077a (patch)
tree52a0b1fa142f3d8b1f6f7753e450fe569848f82a /c++/src
parent0d6737c3d11b407f7ba5647d0f2080507fd28e0e (diff)
downloadhdf5-f11d4727554c852a9deff20ae73971bd73e8077a.zip
hdf5-f11d4727554c852a9deff20ae73971bd73e8077a.tar.gz
hdf5-f11d4727554c852a9deff20ae73971bd73e8077a.tar.bz2
[svn-r15708] I changed the return values of H5Fget_obj_ids and H5Fget_obj_count to ssize_t and modified
C++ and Fortran API functions. This is for bug #1245. Tested on kagiso - I've tested the same change for the trunk using h5committest.
Diffstat (limited to 'c++/src')
-rw-r--r--c++/src/H5File.cpp12
-rw-r--r--c++/src/H5File.h6
2 files changed, 9 insertions, 9 deletions
diff --git a/c++/src/H5File.cpp b/c++/src/H5File.cpp
index 4a48e38..0737a06 100644
--- a/c++/src/H5File.cpp
+++ b/c++/src/H5File.cpp
@@ -378,9 +378,9 @@ hssize_t H5File::getFreeSpace() const
/// Multiple object types can be combined with the logical OR operator (|).
// Programmer Binh-Minh Ribler - May 2004
//--------------------------------------------------------------------------
-int H5File::getObjCount(unsigned types) const
+ssize_t H5File::getObjCount(unsigned types) const
{
- int num_objs = H5Fget_obj_count(id, types);
+ ssize_t num_objs = H5Fget_obj_count(id, types);
if( num_objs < 0 )
{
throw FileIException("H5File::getObjCount", "H5Fget_obj_count failed");
@@ -397,9 +397,9 @@ int H5File::getObjCount(unsigned types) const
///\exception H5::FileIException
// Programmer Binh-Minh Ribler - May 2004
//--------------------------------------------------------------------------
-int H5File::getObjCount() const
+ssize_t H5File::getObjCount() const
{
- int num_objs = H5Fget_obj_count(id, H5F_OBJ_ALL);
+ ssize_t num_objs = H5Fget_obj_count(id, H5F_OBJ_ALL);
if( num_objs < 0 )
{
throw FileIException("H5File::getObjCount", "H5Fget_obj_count failed");
@@ -432,9 +432,9 @@ int H5File::getObjCount() const
// Notes: will do the overload for this one after hearing from Quincey???
// Programmer Binh-Minh Ribler - May 2004
//--------------------------------------------------------------------------
-void H5File::getObjIDs(unsigned types, int max_objs, hid_t *oid_list) const
+void H5File::getObjIDs(unsigned types, size_t max_objs, hid_t *oid_list) const
{
- herr_t ret_value = H5Fget_obj_ids(id, types, max_objs, oid_list);
+ ssize_t ret_value = H5Fget_obj_ids(id, types, max_objs, oid_list);
if( ret_value < 0 )
{
throw FileIException("H5File::getObjIDs", "H5Fget_obj_ids failed");
diff --git a/c++/src/H5File.h b/c++/src/H5File.h
index f5d8dea..f022d66 100644
--- a/c++/src/H5File.h
+++ b/c++/src/H5File.h
@@ -60,12 +60,12 @@ class H5_DLLCPP H5File : public IdComponent, public CommonFG {
// Returns the number of opened object IDs (files, datasets, groups
// and datatypes) in the same file.
- int getObjCount(unsigned types) const;
- int getObjCount() const;
+ ssize_t getObjCount(unsigned types) const;
+ ssize_t getObjCount() const;
// Retrieves a list of opened object IDs (files, datasets, groups
// and datatypes) in the same file.
- void getObjIDs(unsigned types, int max_objs, hid_t *oid_list) const;
+ void getObjIDs(unsigned types, size_t max_objs, hid_t *oid_list) const;
// Retrieves the type of object that an object reference points to.
H5G_obj_t getRefObjType(void *ref, H5R_type_t ref_type = H5R_OBJECT) const;