When clearing scrollback release used memory beyond ~2000 lines
This commit is contained in:
parent
98dcb32a0c
commit
57583d6b00
@ -180,6 +180,8 @@ historybuf_clear(HistoryBuf *self) {
|
|||||||
pagerhist_clear(self);
|
pagerhist_clear(self);
|
||||||
self->count = 0;
|
self->count = 0;
|
||||||
self->start_of_data = 0;
|
self->start_of_data = 0;
|
||||||
|
for (size_t i = 1; i < self->num_segments; i++) free_segment(self->segments + i);
|
||||||
|
self->num_segments = 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
static bool
|
static bool
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user