Revert "Revert some changes"

This reverts commit 64d64d5050.
This commit is contained in:
Linus Dierheimer
2022-09-23 19:54:18 +02:00
parent 4b0b6c9000
commit f33f172734
2 changed files with 2 additions and 2 deletions
+1 -1
View File
@@ -1447,7 +1447,7 @@ int main(int argc, const char** argv)
//If we don't have a custom structure, use the default one
if(data.structure.length == 0)
ffStrbufSetS(&data.structure, FASTFETCH_DATATEXT_STRUCTURE);
ffStrbufAppendS(&data.structure, FASTFETCH_DATATEXT_STRUCTURE);
ffStart(&instance);
+1 -1
View File
@@ -43,7 +43,7 @@ void ffStrbufEnsureFree(FFstrbuf* strbuf, uint32_t free)
uint32_t allocate = strbuf->allocated;
if(allocate < 2)
allocate = 2;
allocate = FASTFETCH_STRBUF_DEFAULT_ALLOC;
while((strbuf->length + free + 1) > allocate) // + 1 for the null byte
allocate *= 2;