This is a workaround for the safe_malloc Error in the Light stage in a Windows 7 64bit environment, if you get something like this:
— SetupTraceNodes —
************ ERROR ************
safe_malloc failed on allocation of 957874176 bytes
It doesn’t solve problems if you have too complex maps but it could expand the amount of memory q3map2 can use by 1GB avoiding the use of the lomem switch. I simply “patched” the q3map2.exe header with the “App can handle > 2GB address space” flag. Without that, q3map2 always crashed wenn the memory consumption reached 2GB. Now it crashes at about 3GB. A 64bit q3map2 release would be much better, but this workaround here could work for some people, too.
I tested it with the latest q3map2.exe from Netradiant, you should make a backup of it before you start if it doesn’t work:
- Download the CFF Explorer Suite
- Open CFF Explorer and then open your q3map2.exe file.
- Go to the “File Header” section (under Nt Headers)
- click the “Click here” on the Characteristics row on the right hand
- check the “App can handle >2gb addressest” box, then click OK
- go to “Save as”, and then rename your existing q3map2.exe (for backup)
- Save the current version as q3map2.exe