@@ -228,7 +228,9 @@ static inline void node_alloc(node_buffer* b, int ask)
229static inline attr* attr_alloc(attr_buffer* b)
229static inline attr* attr_alloc(attr_buffer* b)
231+ // Ensure there is at least one node left
231− if (b->size <= b->used)
232+ int space = b->size - b->used;
233 int size2 = (b->size + 1000) * 2;
235 int size2 = (b->size + 1000) * 2;
234 attr* buf2 = malloc(size2 * sizeof(attr));
236 attr* buf2 = malloc(size2 * sizeof(attr));