rem: if (tmp->text) free(tmp->text);  free(tmp); }  lPtr->itemCount--;
add: WMDeleteFromBag(lPtr->items, row);
context: WMRemoveListItem(WMList *lPtr, int row){    WMListItem *llist;    WMListItem *tmp;    int topItem = lPtr->topItem;    int selNotify = 0;    CHECK_CLASS(lPtr, WC_List);        if (row < 0 || row >= lPtr->itemCount)	return;    if (lPtr->selectedItem == row) {        lPtr->selectedItem = -1;        selNotify = 1;    } else if (lPtr->selectedItem > row) {        lPtr->selectedItem--;    }        if (row <= lPtr->topItem+lPtr->fullFitLines+lPtr->flags.dontFitAll)	lPtr->topItem--;    if (lPtr->topItem < 0)	lPtr->topItem = 0;    if (row == 0) {		if (lPtr->items->text)	    free(lPtr->items->text);		tmp = lPtr->items->nextPtr;	free(lPtr->items);		lPtr->items = tmp;    } else {	llist = lPtr->items;	while (--row > 0)	    llist = llist->nextPtr;	tmp = llist->nextPtr;	llist->nextPtr = llist->nextPtr->nextPtr;	if (tmp->text)	    free(tmp->text);	free(tmp);    }        lPtr->itemCount--;    if (!lPtr->idleID) {	lPtr->idleID = WMAddIdleHandler((WMCallback*)updateScroller, lPtr);    }    if (lPtr->topItem != topItem)    	WMPostNotificationName(WMListDidScrollNotification, lPtr, NULL);    if (selNotify)        WMPostNotificationName(WMListSelectionDidChangeNotification, lPtr,                               (void*)((int)lPtr->selectedItem));}