Ignore:
Timestamp:
Jun 16, 2009 1:01:57 AM (12 years ago)
Author:
pbelotti
Message:

pointers to CouenneObject? were deleted more than once as there are multiple copies of CouenneProblem?

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/Couenne/src/problem/CouenneProblemConstructors.cpp

    r151 r153  
    137137  feas_tolerance_ (p.feas_tolerance_),
    138138  dependence_   (p.dependence_),
    139   objects_      (p.objects_),
     139  objects_      (p.objects_), // NO! have to copy all of them
    140140  integerRank_  (NULL),
    141141  numberInRank_ (p.numberInRank_),
     
    225225  // clear objects_, but only those elements that were copied from the
    226226  // nullObject in fillDependence.cpp
    227   for (std::vector <CouenneObject *>::iterator i = objects_.begin ();
    228        i != objects_. end (); ++i)
    229     if ((*i) -> Reference () == NULL)
    230       delete (*i);
     227  // for (std::vector <CouenneObject *>::iterator i = objects_.begin ();
     228  //        i != objects_. end (); ++i)
     229//     //if ((*i) && ((*i) -> Reference () == NULL))
     230//       delete (*i);
    231231}
Note: See TracChangeset for help on using the changeset viewer.