]> de.git.xonotic.org Git - xonotic/darkplaces.git/blobdiff - prvm_execprogram.h
Add missed check for prvm_garbagecollection_enable in LOAD_S opcode
[xonotic/darkplaces.git] / prvm_execprogram.h
index a6c45c98c47379dbada45e3111ef193b43626aa7..60a112c1c2dcb02d55644d8931cf8dae35375558 100644 (file)
@@ -428,7 +428,8 @@ extern cvar_t prvm_garbagecollection_enable;
                                // against a certain sort of repeated migration to earlier
                                // points in the scan that could otherwise result in the string
                                // being freed for being unused
-                               PRVM_GetString(prog, OPC->_int);
+                               if(prvm_garbagecollection_enable.integer)
+                                       PRVM_GetString(prog, OPC->_int);
                                DISPATCH_OPCODE();
 
                        HANDLE_OPCODE(OP_LOAD_V):