Coder Social home page Coder Social logo

flightsdcpp's Introduction

flightsdcpp's People

Contributors

3f avatar

Stargazers

 avatar

Watchers

 avatar  avatar  avatar

Forkers

radtek

flightsdcpp's Issues

#8: memory leaks :: SearchFrm

в общем забил я на перенос задачек и wiki от разных репо - даже если bitbucket вконец загнется, то не велика потеря

ранее обнаруженные в 3529510

фишка судя по всему с TypedTreeListViewCtrl::deleteAllItems, возможно дебош совместный с insertItem...

нужно глянуть как можно скорее

Для заметки:

Утечка наступает при рассылки сообщений листу - LVM_DELETEALLITEMS в работе с фильтрацией.

SearchInfoList заполняется после очистки из его парентов, но часть записей может присутствовать только в конечном списке(?), соответственно deleteAllItems() проходиться только по parents, а GetItemCount будет равен 0. Вот и получается что мы не можем сослаться на часть записей для высвобождения из heap по завершению

Основной вопрос, почему часть записей летит мимо парента. Проверить это можно переписав очистку следующим образом:

for(SearchInfoList::ParentMap::const_iterator it = ctrlResults.getParents().begin(); it != ctrlResults.getParents().end(); ++it){
    ctrlResults.deleteItem((*it).second.parent);
}

далее можно тогда:

while(ctrlResults.GetItemCount() > 0){
    SearchInfo* si = ctrlResults.getItemData(0);
    //delete si;
    ctrlResults.DeleteItem(0);
}

но если высвобождать оставшиеся с delete, то иногда может возникать break инструкций, значит где-то когда-то это продолжает использоваться

о_о

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.