[Clp-tickets] [COIN-OR Linear Programming Solver] #18: Memory crash in CLP, file ClpPrimalColumnSteepest.cpp; pivotsequence

COIN-OR Linear Programming Solver coin-trac at coin-or.org
Wed Feb 13 20:43:09 EST 2008


#18: Memory crash in CLP, file ClpPrimalColumnSteepest.cpp; pivotsequence
------------------------------------------------------------------------+---
 Reporter:  ltaylor                                                     |       Owner:  somebody
     Type:  defect                                                      |      Status:  new     
 Priority:  major                                                       |   Milestone:          
Component:  component1                                                  |     Version:          
 Keywords:  vector memory access pivot variable primal column steepest  |  
------------------------------------------------------------------------+---
 I am using MS Visual Basic to call COINMP, which uses the clp code.

 The application caught an exception while performing LP; crash was
 accessing forbidden memory.

 I had had several crashes previously, but I had not been able to
 catch it. This time, debugging was turned on for all modules down
 to this one.
 clpprimalcolumnsteepest.cpp
 about line 2804
 file appears to be current as of today, 2-13-08

 This is the code:
 {{{
         if (pivotSequence_>=0) {
           // save pivot order
           CoinMemcpyN(pivotVariable,
                  numberRows,alternateWeights_->getIndices());
           // change from pivot row number to sequence number
           pivotSequence_=pivotVariable[pivotSequence_];
         }

 }}}

 I am guessing from the comment and from the code that it probably
 should be a reference like this instead ...

 {{{
 pivotSequence_ =pivotVariable[pivotRow]
 }}}

 When debugging caught the error, pivotSequence_ was 2961, while
 the capacity of pivotVariable was only 199.

 The attached file contains:[[BR]]

 * locals[[BR]]

 * error message as given by MS Visual Studio[[BR]]

 * stack trace[[BR]]

-- 
Ticket URL: <https://projects.coin-or.org/Clp/ticket/18>
COIN-OR Linear Programming Solver <http://projects.coin-or.org/Clp>
A linear programming solver.



More information about the Clp-tickets mailing list