Changeset 1482 for stable


Ignore:
Timestamp:
Dec 22, 2009 5:03:10 AM (10 years ago)
Author:
forrest
Message:

make copy constructor more logical

File:
1 edited

Legend:

Unmodified
Added
Removed
  • stable/1.11/Clp/src/ClpModel.cpp

    r1458 r1482  
    777777      savedColumnScale_ = NULL;
    778778      integerType_ = CoinCopyOfArray(rhs.integerType_,numberColumns_);
    779       if (rhs.rowActivity_) {
    780         rowActivity_= ClpCopyOfArray(rhs.rowActivity_, numberRows_);
    781         columnActivity_= ClpCopyOfArray(rhs.columnActivity_,numberColumns_);
    782         dual_= ClpCopyOfArray(rhs.dual_, numberRows_);
    783         reducedCost_= ClpCopyOfArray(rhs.reducedCost_, numberColumns_);
    784       } else {
    785         rowActivity_=NULL;
    786         columnActivity_=NULL;
    787         dual_=NULL;
    788         reducedCost_=NULL;
    789       }
     779      rowActivity_= ClpCopyOfArray(rhs.rowActivity_, numberRows_);
     780      columnActivity_= ClpCopyOfArray(rhs.columnActivity_,numberColumns_);
     781      dual_= ClpCopyOfArray(rhs.dual_, numberRows_);
     782      reducedCost_= ClpCopyOfArray(rhs.reducedCost_, numberColumns_);
    790783      rowLower_ = ClpCopyOfArray ( rhs.rowLower_, numberRows_ );
    791784      rowUpper_ = ClpCopyOfArray ( rhs.rowUpper_, numberRows_ );
Note: See TracChangeset for help on using the changeset viewer.