[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:
Binh-Minh Ribler 2001-03-06 02:08:33 -05:00
parent e99887cc66
commit f1932cb582
2 changed files with 7 additions and 7 deletions

View File

@ -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 ){}

View File

@ -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 );