mirror of
https://git.code.sf.net/p/quake/quakeforge
synced 2024-11-26 22:31:05 +00:00
fix an out-by-one error that caused a buffer overrun and a crash in windows
This commit is contained in:
parent
23f71485d1
commit
318a945a9c
1 changed files with 1 additions and 1 deletions
|
@ -384,7 +384,7 @@ add_sel_name (progs_t *pr, const char *name)
|
|||
int ind = ++pr->selector_index;
|
||||
int size, i;
|
||||
|
||||
if (pr->selector_index > pr->selector_index_max) {
|
||||
if (pr->selector_index >= pr->selector_index_max) {
|
||||
size = pr->selector_index_max + 128;
|
||||
pr->selector_sels = realloc (pr->selector_sels,
|
||||
size * sizeof (obj_list *));
|
||||
|
|
Loading…
Reference in a new issue