From 20831ddc6c0839f7b85d3c717e8a8e0b3fa46838 Mon Sep 17 00:00:00 2001 From: "Wolfgang (Blub) Bumiller" Date: Sat, 11 Aug 2012 21:17:49 +0200 Subject: [PATCH] fixing address check INSTR_STOREP_V in execloop - it kept us from writing to a vector when it was the last declared entityfield --- execloop.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/execloop.h b/execloop.h index 2929c2d..6ccfad4 100644 --- a/execloop.h +++ b/execloop.h @@ -216,7 +216,7 @@ ptr->_int = OPA->_int; break; case INSTR_STOREP_V: - if (OPB->_int < 0 || OPB->_int + 3 >= prog->entitydata_count) + if (OPB->_int < 0 || OPB->_int + 2 >= prog->entitydata_count) { PRVM_ERROR("%s attempted to write to an out of bounds edict (%i)", PRVM_NAME, OPB->_int); goto cleanup; -- 2.39.2