Fix memory leak.

PR: kern/15363
Submitted by: Oliver Fromme
This commit is contained in:
Kazutaka YOKOTA 1999-12-10 09:36:05 +00:00
parent 0712c356a3
commit da7c907d09

View File

@ -135,6 +135,7 @@ sc_alloc_history_buffer(scr_stat *scp, int lines, int prev_ysize, int wait)
if (prev_history != NULL) { if (prev_history != NULL) {
extra_history_size += delta; extra_history_size += delta;
sc_vtb_destroy(prev_history); sc_vtb_destroy(prev_history);
free(prev_history, M_DEVBUF);
} }
scp->history = history; scp->history = history;