Fix disabled layers forcing realloc

This commit is contained in:
Simon Ser 2023-02-16 19:51:42 +01:00
parent 2f461be62c
commit 63c6043b15

View file

@ -562,6 +562,10 @@ layer_needs_realloc(struct liftoff_layer *layer)
* attributes didn't change, we can try to re-use the previous
* allocation. */
if (strcmp(prop->name, "FB_ID") == 0) {
if (prop->value == 0 && prop->prev_value == 0) {
continue;
}
if (prop->value == 0 || prop->prev_value == 0) {
return true;
}