From 20ad50407d0b683ac2ceca2645032ef8a33c5e60 Mon Sep 17 00:00:00 2001 From: Bill Currie Date: Fri, 6 Jul 2012 10:53:24 +0900 Subject: [PATCH] Correct the size adjustment for qwe's newstr. It seems the correct interpretation is that the size parameter includes the trailing 0 (going by mvdsv source). --- qw/source/sv_pr_qwe.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/qw/source/sv_pr_qwe.c b/qw/source/sv_pr_qwe.c index ec86ca87f..e7cecdb70 100644 --- a/qw/source/sv_pr_qwe.c +++ b/qw/source/sv_pr_qwe.c @@ -254,7 +254,7 @@ PF_newstr (progs_t *pr) if (pr->pr_argc > 1 && P_FLOAT (pr, 1) > dstr->size) { int s = dstr->size; - dstr->size = P_FLOAT (pr, 1) + 1; + dstr->size = P_FLOAT (pr, 1); dstring_adjust (dstr); memset (dstr->str + s, 0, dstr->size - s); }