diff options
author | Fox Caminiti <fox@foxcam.net> | 2022-10-06 14:30:48 -0400 |
---|---|---|
committer | Fox Caminiti <fox@foxcam.net> | 2022-10-06 14:30:48 -0400 |
commit | 0b0aa3b06fac0bcdeb31d5e2211d1ba149531692 (patch) | |
tree | 91f0d9689151b7fb985de50b2c8b12ccd7a65440 /strings.cpp | |
parent | a4c1e537b0cb2540535357d880e46f63b38c134f (diff) |
GL renderer preparation
Diffstat (limited to 'strings.cpp')
-rw-r--r-- | strings.cpp | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/strings.cpp b/strings.cpp index b8560d1..ab410b2 100644 --- a/strings.cpp +++ b/strings.cpp @@ -27,10 +27,12 @@ static uint16 String_AddToFile(memory *Memory, char *Char) { uint16 FileIndex = Memory_Block_AllocateNew(Memory, F_Strings); - void *Address = Memory_Block_AddressAtIndex(Memory, F_Strings, FileIndex); + block_string *String = (block_string *)Memory_Block_AddressAtIndex(Memory, F_Strings, FileIndex); + History_Action_Block_Swap(Memory, F_Strings, String); + String->Occupied = 1; uint16 i = 0; while (Char[i] != '\0') { - *((char *)Address + i) = Char[i]; + String->Char[i] = Char[i]; i++; } return FileIndex; |