Ignore:
Timestamp:
Feb 25, 2008, 10:24:40 PM (14 years ago)
Author:
Peter
Message:

fixes #294

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/yat/utility/Vector.cc

    r1136 r1147  
    7474    : VectorMutable()
    7575  {
     76    if (!is.good())
     77      throw utility::IO_error("Vector: istream is not good");
     78
    7679    // read the data file and store in stl vectors (dynamically
    7780    // expandable)
     
    134137    // manipulate the state of the stream to be good
    135138    is.clear(std::ios::goodbit);
     139
     140    if (!nof_columns || !nof_rows)
     141      return;
     142
    136143    // convert the data to a gsl vector
    137144    vec_ = gsl_vector_alloc(nof_rows*nof_columns);
Note: See TracChangeset for help on using the changeset viewer.