JAListView icon indicating copy to clipboard operation
JAListView copied to clipboard

memory leak of JAListViewItem in non ARC

Open mammaiap opened this issue 10 years ago • 0 comments

Hi ,

I found that "JAListViewItem and DemoView" are not deallocated.

if i add the autorelease in the line

  • (JAListViewItem *)listView:(JAListView *)listView viewAtIndex:(NSUInteger)index { DemoView *view = [[DemoView demoView]autorelease];

    return view; }

then it JAListViewItem and DemoView "dealloc " was called...

but the problem is that...

when i call the reloadData... and try to drag and drop" it crash and it says "view is already released"... that means "list view still showing the released views"...that makes the crash..

if i not add the autorelease then it wont crash... but "JAListViewItem and DemoView" dealloc is not yet called...

please help me to fix the problem. i need to fix the memory leak as well as "crash"...

Thanks & Regards, Muthu

mammaiap avatar Nov 14 '14 11:11 mammaiap