mfc 定时多线程运行一段时间后 内存满了,是哪里出现问题了?怎么弄
SYSTEMTIME st;GetLocalTime(&st);
DWORD CurrentTime,jisuanTime = 0, huanhang = 0, huanhangjisu = 0, val = 0;
DWORD hang[100], hangshu = 0;
CString l_str1, l_str3, code, longcode;
CurrentTime = st.wHour * 60 * 60 + st.wMinute * 60 + st.wSecond;
int l_int = (int )Context;
HWND l_hwnd;RECT rctA; HDC g_memDc; HDC disDc;
l_hwnd = All_hwnd[l_int];
shibieCode shibie;
SaveSymGuocheng savesymguocheng;
savesymguocheng.线程 = l_int;
::GetWindowRect(l_hwnd, &rctA);
int src_x = rctA.right - rctA.left;
int src_y = rctA.bottom - rctA.top + 2;
disDc = ::GetWindowDC(l_hwnd);
g_memDc = CreateCompatibleDC(disDc);
HBITMAP hbitMap = CreateCompatibleBitmap(disDc, src_x, src_y);
SelectObject(g_memDc, hbitMap);
BitBlt(g_memDc, 0, 0, src_x, src_y, disDc, 0, 0, SRCCOPY);
BITMAP bmpInfo;
LPBYTE lpOrigiPixel = NULL;
DWORD dwOigiPixelLen = 0;
memset(&bmpInfo, 0, sizeof(BITMAP));
GetObjectA(hbitMap, sizeof(BITMAP), &bmpInfo);
dwOigiPixelLen = bmpInfo.bmWidthbmpInfo.bmHeight * 4;
DWORD dwPixels = bmpInfo.bmWidthbmpInfo.bmHeight;
lpOrigiPixel = new BYTE[dwOigiPixelLen];
GetBitmapBits(hbitMap, dwOigiPixelLen, lpOrigiPixel);
DWORD l_kaishihang = 0;
ReleaseDC(l_hwnd, disDc);
ReleaseDC(l_hwnd, g_memDc);
DeleteObject(hbitMap);
delete[]lpOrigiPixel;
Sleep(10);
return;