On 2010-09-22 at 14:54:57 [+0200], Stephan Assmus <superstippi@xxxxxx> wrote: > Hi, > > > @@ -245,7 +246,7 @@ > > > > TeamListItem* item = new(std::nothrow) TeamListItem(team); > > if (item != NULL) { > > - AddItem(new TeamListItem(team)); > > + AddItem(item); > > SortItems(&TeamListItem::Compare); > > } > > break; > > BTW, if AddItem() is the BList AddItem(), it potentially returns "false", > since it potentially needs to make an allocation itself. So the correct > code would be to check the AddItem() return value and delete the item if > it's "false" and then bail out. Good hint. Apparently that had been forgotten in the TeamWindow as well. CU, Ingo