summaryrefslogtreecommitdiffstats
path: root/c++/src/H5File.cpp
diff options
context:
space:
mode:
authorBinh-Minh Ribler <bmribler@hdfgroup.org>2016-04-22 11:22:34 (GMT)
committerBinh-Minh Ribler <bmribler@hdfgroup.org>2016-04-22 11:22:34 (GMT)
commitc37607eb58994041cbeaabdab5f1e9902794a3e9 (patch)
treeb96792d17d5bce03ad862b556f137a7b06c1449d /c++/src/H5File.cpp
parentc63f96d6e78cfe98de8001b662ec685467fd65df (diff)
downloadhdf5-c37607eb58994041cbeaabdab5f1e9902794a3e9.zip
hdf5-c37607eb58994041cbeaabdab5f1e9902794a3e9.tar.gz
hdf5-c37607eb58994041cbeaabdab5f1e9902794a3e9.tar.bz2
[svn-r29759] Purpose: Code improvements
Description: - Changed object in catch statements to reference - Replaced old-style casts or reinterpret_cast with static_cast - Removed unused name H5Library::need_cleanup - Removed Exception::printError from documentation Platforms tested: Linux/32 2.6 (jam) Linux/64 (platypus) Darwin (osx1010test)
Diffstat (limited to 'c++/src/H5File.cpp')
-rw-r--r--c++/src/H5File.cpp10
1 files changed, 5 insertions, 5 deletions
diff --git a/c++/src/H5File.cpp b/c++/src/H5File.cpp
index 67dda34..e63694a 100644
--- a/c++/src/H5File.cpp
+++ b/c++/src/H5File.cpp
@@ -88,7 +88,7 @@ H5File::H5File( const char* name, unsigned int flags, const FileCreatPropList& c
{
try {
p_get_file(name, flags, create_plist, access_plist);
- } catch (FileIException open_file) {
+ } catch (FileIException& open_file) {
throw open_file;
}
}
@@ -113,7 +113,7 @@ H5File::H5File( const H5std_string& name, unsigned int flags, const FileCreatPro
{
try {
p_get_file(name.c_str(), flags, create_plist, access_plist);
- } catch (FileIException open_file) {
+ } catch (FileIException& open_file) {
throw open_file;
}
}
@@ -245,7 +245,7 @@ void H5File::openFile(const char* name, unsigned int flags, const FileAccPropLis
try {
close();
}
- catch (Exception close_error) {
+ catch (Exception& close_error) {
throw FileIException("H5File::openFile", close_error.getDetailMsg());
}
@@ -294,7 +294,7 @@ void H5File::reOpen()
try {
close();
}
- catch (Exception close_error) {
+ catch (Exception& close_error) {
throw FileIException("H5File::reOpen", close_error.getDetailMsg());
}
@@ -650,7 +650,7 @@ H5File::~H5File()
{
try {
close();
- } catch (Exception close_error) {
+ } catch (Exception& close_error) {
cerr << "H5File::~H5File - " << close_error.getDetailMsg() << endl;
}
}