From 79b1590ff025e303838eb307187331e89ef4e2af Mon Sep 17 00:00:00 2001 From: Allen Webster Date: Sat, 24 Sep 2016 11:37:49 -0400 Subject: [PATCH 1/2] quick patch for 4.0.11 users with big files --- 4coder_default_include.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/4coder_default_include.cpp b/4coder_default_include.cpp index b1e54991..5ca9ffcd 100644 --- a/4coder_default_include.cpp +++ b/4coder_default_include.cpp @@ -120,8 +120,8 @@ static General_Memory global_general; void init_memory(Application_Links *app){ - int32_t part_size = (1 << 20); - int32_t general_size = (1 << 20); + int32_t part_size = (32 << 20); + int32_t general_size = (4 << 20); void *part_mem = memory_allocate(app, part_size); From 45ed69c9f017532a3c29b41e496f71e6f24a8a49 Mon Sep 17 00:00:00 2001 From: Allen Webster Date: Sat, 24 Sep 2016 16:58:05 -0400 Subject: [PATCH 2/2] Fixed nasty crashing bug in the 4.0.11 branch --- 4cpp_lexer.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/4cpp_lexer.h b/4cpp_lexer.h index 1ce4134d..1a96bbe1 100644 --- a/4cpp_lexer.h +++ b/4cpp_lexer.h @@ -799,7 +799,7 @@ cpp_lex_nonalloc_null_end_no_limit(Cpp_Lex_Data *S_ptr, char *chunk, int32_t siz break; } - if (chunk[S.pos-1] == 0){ + if (S.pos > S.chunk_pos && chunk[S.pos-1] == 0){ --S.pos; }