Commit graph

7 commits

Author SHA1 Message Date
Daniel Gibson
5c9d9ff53c Implement Mem_MallocA()+Mem_FreeA(): alloca() but might use Heap
When requesting < 1 MB, _alloca16() is used, otherwise Mem_Alloc16().
Furthermore you must pass a bool that will get true assigned if the
memory has been allocated on the stack, else false.
At the end of the function you must call Mem_FreeA( ptr, onStack )
(where onStack is the aforementioned bool), so Mem_Free16() can be
called if it was allocated on the heap.
2024-11-07 06:25:51 +01:00
dhewg
826dfb0e5b Fix alignment issue with idBlockAlloc::Free()
Bug introduced with e97d3288. This doesn't work with MinGW, since
the struct members might not be aligned to the native pointer
size (in this case idSampleDecoderLocal was aligned to a 8 byte
boundary on win32).
Just switch the two members to avoid ugly code.
2011-12-22 18:51:17 +01:00
dhewg
736ec20d4d Untangle the epic precompiled.h mess
Don't include the lazy precompiled.h everywhere, only what's
required for the compilation unit.
platform.h needs to be included instead to provide all essential
defines and types.
All includes use the relative path to the neo or the game
specific root.
Move all idlib related includes from idlib/Lib.h to precompiled.h.
precompiled.h still exists for the MFC stuff in tools/.
Add some missing header guards.
2011-12-19 23:21:47 +01:00
dhewg
e97d328804 Fix -Winvalid-offsetof warnings 2011-12-10 15:36:06 +01:00
dhewg
79ad905e05 Fix all whitespace errors
Excluding 3rd party files.
2011-12-10 15:35:54 +01:00
dhewg
ff493f6847 Fix quoting in GPL headers 2011-12-10 15:34:48 +01:00
Timothee 'TTimo' Besset
fb1609f554 hello world 2011-11-22 15:28:15 -06:00