根据配置禁用mmap缓存 (#1429)

This commit is contained in:
xiongguangjie
2022-02-17 10:35:10 +08:00
committed by GitHub
parent af08b58d29
commit 9c45fca761
4 changed files with 22 additions and 3 deletions

View File

@@ -127,6 +127,8 @@ const string kNotFound = HTTP_FIELD"notFound";
//是否显示文件夹菜单
const string kDirMenu = HTTP_FIELD"dirMenu";
const string kForbidCacheSuffix = HTTP_FIELD"forbidCacheSuffix";
onceToken token([](){
mINI::Instance()[kSendBufSize] = 64 * 1024;
mINI::Instance()[kMaxReqSize] = 4 * 10240;
@@ -151,6 +153,7 @@ onceToken token([](){
"</body>"
"</html>"
<< endl;
mINI::Instance()[kForbidCacheSuffix] = "";
},nullptr);
}//namespace Http