diff --git a/met/src/basic/vx_util/data_line.cc b/met/src/basic/vx_util/data_line.cc index ab16353db1..1853449b65 100644 --- a/met/src/basic/vx_util/data_line.cc +++ b/met/src/basic/vx_util/data_line.cc @@ -253,7 +253,11 @@ const char * DataLine::get_item(int k) const if ( (k < 0) || (k >= N_items) ) { - mlog << Error << "\nDataLine::get_item(int) -> range check error\n\n"; + ConcatString filename = (get_file() ? get_file()->filename() : ""); + + mlog << Error << "\nDataLine::get_item(int) -> " + << "range check error while reading item number " << k+1 + << " from file \"" << filename << "\"\n\n"; exit ( 1 ); @@ -640,7 +644,8 @@ LineDataFile::LineDataFile(const LineDataFile &) { -mlog << Error << "\nLineDataFile::LineDataFile(const LineDataFile &) -> should never be called!\n\n"; +mlog << Error << "\nLineDataFile::LineDataFile(const LineDataFile &) -> " + << "should never be called!\n\n"; exit ( 1 ); @@ -654,7 +659,8 @@ LineDataFile & LineDataFile::operator=(const LineDataFile &) { -mlog << Error << "\nLineDataFile::operator=(const LineDataFile &) -> should never be called!\n\n"; +mlog << Error << "\nLineDataFile::operator=(const LineDataFile &) -> " + << "should never be called!\n\n"; exit ( 1 ); @@ -698,7 +704,8 @@ in = new ifstream; if ( !in ) { - mlog << Error << "\nLineDataFile::open(const char *) -> can't allocate input stream\n\n"; + mlog << Error << "\nLineDataFile::open(const char *) -> " + << "can't allocate input stream\n\n"; exit ( 1 );