mirror of
https://github.com/gryf/wmaker.git
synced 2025-12-21 13:28:05 +01:00
Fixed wrealloc() to be consistent with the wmalloc() behaviour when it cannot
allocate memory.
This commit is contained in:
@@ -146,10 +146,6 @@ WMInsertItemInTabView(WMTabView *tPtr, int index, WMTabViewItem *item)
|
||||
|
||||
items = wrealloc(tPtr->items,
|
||||
sizeof(WMTabViewItem*) * (tPtr->maxItems + 10));
|
||||
if (!items) {
|
||||
wwarning("out of memory allocating memory for tabview");
|
||||
return;
|
||||
}
|
||||
memset(&items[tPtr->maxItems], 0, sizeof(WMTabViewItem*) * 10);
|
||||
tPtr->items = items;
|
||||
tPtr->maxItems += 10;
|
||||
|
||||
Reference in New Issue
Block a user