这段代码为什么会报错啊?
char MYEXEPathA[255];
CString MYEXEPath ;
CString MYINIPathFile;
::GetCurrentDirectory(255,MYEXEPathA);
MYEXEPath=MYEXEPathA;
MYINIPathFile=MYEXEPath+"\\test.ini";
void GetIniTest(CString& str,DWORD i=1)
{
LPSTR tastr;
CString testr;
testr.Format("ABC%d",i);
::GetPrivateProfileString("ListUser",testr,"",tastr,20,MYINIPathFile);
str.Format("%s",tastr);
}
CString showstr;
GetIniTest(showstr);以上代码,在GetIniTest执行完毕的时候会跳到free.c文件中,这是为什么啊?
#ifdef CRTDLL
else if ( __active_heap == __V5_HEAP )
{
__old_sbh_region_t *preg;
__old_sbh_page_t * ppage;
__old_page_map_t * pmap;
_mlock(_HEAP_LOCK );
__try {
if ( (pmap = __old_sbh_find_block(pBlock, &preg, &ppage)) != NULL )
__old_sbh_free_block(preg, ppage, pmap);
}
__finally {
_munlock(_HEAP_LOCK );
}
if (pmap == NULL)
{
retval = HeapFree(_crtheap, 0, pBlock);
if (retval == 0)
{
errno = _get_errno_from_oserr(GetLastError());
}
}
}
#endif /* CRTDLL */
else // __active_heap == __SYSTEM_HEAP
#endif /* _WIN64 */
{
retval = HeapFree(_crtheap, 0, pBlock);
if (retval == 0) //就中断在这里!
{
errno = _get_errno_from_oserr(GetLastError());
}
}
}
...全文
相关推荐
奔图打印机报错代码对照表
奔图打印机报错代码对照表
程序有误,为什么Keil却没有报错
这两天在整1602,程序都写完后用Keil编译,有报错,但后来都一一解决了,于是烧进单片机,可不管怎么调1602就是不显示,最后我只得对照书上的源程序,一个字母一个字母比对......
spring boot项目导入依赖后代码报错问题的解决方法
主要给大家介绍了关于spring boot项目导入依赖后代码报错问题的解决方法,文中通过示例代码介绍的非常详细,对大家学习或者使用spring Boot具有一定的参考学习价值,需要的朋友们下面来一起学习学习吧
IBM-DS-存储的报错代码详细介绍
讲解IBM存的报错CoreID,已经解决方案,对各个案例的剖析。
报错 代码 经验
是一个很有经验的人的阐述。


