nagyistoce / platinum-image

Automatically exported from code.google.com/p/platinum-image
0 stars 0 forks source link

Crash when removing an image #44

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
The program crashes in data_vector_has_changed() when removing an image.

void rendercombination::data_vector_has_changed()
    {
    //images may have been deleted too, we need to update both image ID 
and image pointer

    for (std::list<renderpair>::iterator itr = renderdata.begin();itr != 
renderdata.end();itr++)
        {
        itr->pointer=datamanagement.get_data(itr->ID); //CRASH HERE

Original issue reported on code.google.com by petter.r...@gmail.com on 7 Aug 2007 at 8:49

GoogleCodeExporter commented 9 years ago
Fixed in revision 379

Original comment by petter.r...@gmail.com on 7 Aug 2007 at 4:24

GoogleCodeExporter commented 9 years ago
Fixed in revision 383
data_base * datamanager::get_data (int ID)
{
    for (vector<data_base*>::iterator itr=dataItems.begin();itr != dataItems.end
();itr++)
        {
        if (**itr == ID)
            {
            return *itr;
            }
        }
    return NULL;//Pretty important line...
}

Original comment by petter.r...@gmail.com on 10 Aug 2007 at 10:56