summaryrefslogtreecommitdiffstats
path: root/c++/src/H5DataType.cpp
diff options
context:
space:
mode:
authorBinh-Minh Ribler <bmribler@hdfgroup.org>2010-09-16 04:13:25 (GMT)
committerBinh-Minh Ribler <bmribler@hdfgroup.org>2010-09-16 04:13:25 (GMT)
commitb0a1e95ac7de5d0235dc0bc0732f4225b1589bad (patch)
treea04daf9a694a6d0eac1ce43853040800076186d4 /c++/src/H5DataType.cpp
parent3755fa1822fdd3a7a68eef9f4a6aabade7dacb56 (diff)
downloadhdf5-b0a1e95ac7de5d0235dc0bc0732f4225b1589bad.zip
hdf5-b0a1e95ac7de5d0235dc0bc0732f4225b1589bad.tar.gz
hdf5-b0a1e95ac7de5d0235dc0bc0732f4225b1589bad.tar.bz2
[svn-r19394] Purpose: Fixed bug 1903
Description: After a C++ API object is closed, its id should be reset regardless of the reference count of the underlying HDF5 object. User reported the bug for Group, but it's applicable to all other objects. Fixed. Platforms tested: Linux/32 2.6 (jam) FreeBSD/64 6.3 (liberty) SunOS 5.10 (linew)
Diffstat (limited to 'c++/src/H5DataType.cpp')
-rw-r--r--c++/src/H5DataType.cpp6
1 files changed, 2 insertions, 4 deletions
diff --git a/c++/src/H5DataType.cpp b/c++/src/H5DataType.cpp
index 4c995e3..6e894dc 100644
--- a/c++/src/H5DataType.cpp
+++ b/c++/src/H5DataType.cpp
@@ -781,10 +781,8 @@ void DataType::close()
{
throw DataTypeIException(inMemFunc("close"), "H5Tclose failed");
}
- // reset the id when the datatype that it represents is no longer
- // referenced
- if (getCounter() == 0)
- id = 0;
+ // reset the id
+ id = 0;
}
}