减少远程桌面new的频次

减少远程桌面new缓冲区的频率,将部分从堆上new固定内存的操作改用从栈上分配内存。
This commit is contained in:
yuanyuanxiang
2019-01-21 21:04:17 +08:00
parent 5aadfc13a6
commit 4283a31e66
9 changed files with 37 additions and 35 deletions

View File

@@ -86,7 +86,6 @@ char* RegisterOperation::FindPath()
if(KeyCount>0&&KeySize>1){
int Size=sizeof(REGMSG)+1;
//buf=new char[KeyCnt*KeySize+size+1];
DWORD DataSize=KeyCount*KeySize+Size+1; //[TOKEN_REG_PATH][2 11 ccccc\0][11][11]
szBuffer=(char*)LocalAlloc(LPTR, DataSize);
ZeroMemory(szBuffer,DataSize);