mirror of
https://git.code.sf.net/p/quake/quakeforge
synced 2025-01-19 07:20:50 +00:00
[qwaq] Allocate enough bytes for the args list
d'oh
This commit is contained in:
parent
68fc11857a
commit
815ae02121
1 changed files with 1 additions and 1 deletions
|
@ -903,7 +903,7 @@ bi_wvprintf (progs_t *pr)
|
|||
const char *fmt = P_GSTRING (pr, 1);
|
||||
__auto_type args = (pr_va_list_t *) &P_POINTER (pr, 2);
|
||||
pr_type_t *list_start = PR_GetPointer (pr, args->list);
|
||||
pr_type_t **list = alloca (args->count);
|
||||
pr_type_t **list = alloca (args->count * sizeof (*list));
|
||||
|
||||
for (int i = 0; i < args->count; i++) {
|
||||
list[i] = list_start + i * pr->pr_param_size;
|
||||
|
|
Loading…
Reference in a new issue