在使用净化器进行内存检查时,它在以下语句中显示 IPR 错误。
throw true;
可能是什么问题?
void Myfunc(char *p_trace_id,char *p_session_id,int &p_roam_flag)
{
try
{
int set_id=0;
if(0 == set_id)
throw true;
}
catch(bool p_return_value)
{
if(!p_return_value)
{
g_Log.log(DEBUG, p_trace_id ,"[%s] %s<Line: %d> ", p_session_id ,__FUNCTION__,__LINE__);
p_roam_flag = 0;
}
}
catch(...)
{
g_Log.log(DEBUG, p_trace_id ,"[%s] %s<Line: %d> ", p_session_id ,__FUNCTION__,__LINE__);
}
}
根据我的分析,旧版本的 purify 存在问题。但我使用的是最新版本。
Purify V7.0
Solaris V5.0