Changeset 905 for branches


Ignore:
Timestamp:
Jan 11, 2007 10:48:04 AM (13 years ago)
Author:
forrest
Message:

empty problem fix

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/devel/Clp/src/ClpSolve.cpp

    r899 r905  
    378378  ClpMatrixBase * saveMatrix=NULL;
    379379  ClpObjective * savedObjective=NULL;
     380  if (!objective_||!matrix_) {
     381    // totally empty
     382    handler_->message(CLP_EMPTY_PROBLEM,messages_)
     383      <<0
     384      <<0
     385      <<0
     386      <<CoinMessageEol;
     387    return -1;
     388  } else if (!numberRows_||!numberColumns_||!getNumElements()) {
     389    presolve = ClpSolve::presolveOff;
     390  }
    380391  if (objective_->type()>=2&&optimizationDirection_==0) {
    381392    // pretend linear
Note: See TracChangeset for help on using the changeset viewer.