Changeset 1074


Ignore:
Timestamp:
Aug 9, 2007 5:20:31 PM (12 years ago)
Author:
stefan
Message:

error handling in case that an mps file from the netlib cannot be opened

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/BSP/trunk/Clp/src/unitTest.cpp

    r1073 r1074  
    437437        // Read data mps file,
    438438        CoinMpsIO mps;
    439         mps.readMps(fn.c_str(),"mps");
     439        int nerrors=mps.readMps(fn.c_str(),"mps");
     440        if (nerrors) {
     441                std::cerr << "Error " << nerrors << " when reading model from " << fn.c_str() << "! "
     442                << "I'll continue with the next model." << std::endl;
     443                continue;
     444        }
    440445        solutionBase.loadProblem(*mps.getMatrixByCol(),mps.getColLower(),
    441446                                 mps.getColUpper(),
Note: See TracChangeset for help on using the changeset viewer.