while(b){
pRecordset=
pConnection->Execute(strSQL,&vRecsAffected,adOptionUnspecified) ;
...
...
...
pRecordset->Close();
}好象执行查询和调用存储过程都有内存泄露,
不间断的循环执行导致系统不停的以每次4k的速度泄露内存,
谁知道如何解决吗,帮帮忙,谢谢?
pRecordset=
pConnection->Execute(strSQL,&vRecsAffected,adOptionUnspecified) ;
...
...
...
pRecordset->Close();
}好象执行查询和调用存储过程都有内存泄露,
不间断的循环执行导致系统不停的以每次4k的速度泄露内存,
谁知道如何解决吗,帮帮忙,谢谢?
pRecordset = NULL;
pRecordset.Release();pRecorset=NULL;CoUninitialize();
Whenever possible, release ADO objects as soon as you're done with them. This frees up the database and other resources that might be expensive to hold for an extended period. Explicitly close all objects rather than allowing the object to close itself as it is destroyed.
if(!pRecordset->adoEOF)
{
int i=0;
}
就出现内存泄露