mirror of
https://github.com/HDFGroup/hdf5.git
synced 2025-02-23 16:20:57 +08:00
[svn-r3550]
Purpose: Bug fix Description: The Exception destructor accidently called H5Eprint, which caused error messages to be printed where they are not supposed to because the failures are expected. Solution: Removed that lousy call! Platforms tested: arabica (sparc-sun-solaris 2.7)
This commit is contained in:
parent
e99887cc66
commit
f1932cb582
@ -120,6 +120,11 @@ string Exception::getDetailMesg() const
|
||||
return( detailMessage );
|
||||
}
|
||||
|
||||
const char* Exception::getCDetailMesg() const
|
||||
{
|
||||
return( detailMessage.c_str() );
|
||||
}
|
||||
|
||||
// Prints the error stack in a default manner.
|
||||
void Exception::printError( FILE* stream ) const
|
||||
{
|
||||
@ -128,12 +133,7 @@ void Exception::printError( FILE* stream ) const
|
||||
throw Exception( "Exception::printError" );
|
||||
}
|
||||
|
||||
Exception::~Exception()
|
||||
{
|
||||
herr_t ret_value = H5Eprint( NULL ); // print to stderr
|
||||
if( ret_value < 0 )
|
||||
throw Exception( "Exception::printError" );
|
||||
}
|
||||
Exception::~Exception() {}
|
||||
|
||||
FileIException::FileIException():Exception(){}
|
||||
FileIException::FileIException( string message ): Exception( message ){}
|
||||
|
@ -32,7 +32,7 @@ class Exception {
|
||||
|
||||
// Returns the detailed message set at the time the exception is thrown
|
||||
string getDetailMesg() const;
|
||||
char* getCDetailMesg(); // C string of detailed message
|
||||
const char* getCDetailMesg() const; // C string of detailed message
|
||||
|
||||
// Turns on the automatic error printing.
|
||||
static void setAutoPrint( H5E_auto_t func, void* client_data );
|
||||
|
Loading…
Reference in New Issue
Block a user