作者LPH66 (小心课业闭锁空间...)
看板Programming
标题Re: [问题] VC6, VC2003, VC2005
时间Sat Jun 17 05:47:26 2006
※ 引述《march20 ()》之铭言:
: ※ 引述《[email protected] ( )》之铭言:
: : 请问有谁能回答一下这个问题
: : 就是阿 我们小组写的象棋程式出了一点问题
: : 同样的程式码在VC6编译出来的程式可以正常执行
: : 但是在2003, 2005编译(Debug模式)出来的程式
: : 在最後程式要结束之前会错误
: : Run-Time Check Failure #2 - Stack around the variable 'sp_icon' was corrupted.
: : 如果用Release模式的话就不会有这个问题
: : 请问到底是为什麽呢?
: 这跟前几篇 gyspy 的问题还满像的, 只不过他的 case 刚好反过来.
: 说真的, 没真的 trace 程式, 不能确定是什麽问题,
: 就遇过的实例来说, 问题八成出在 pointer 上.
: 要不要检查看看有没有 dangling pointer ?
dangling pointer好像比较不会破坏到内部堆叠...
找找是不是有阵列存取超出范围
或者是指标加减弄一弄就弄到不知道指向什麽地方去的指标
--
'Oh, Harry, dont't you
see?' Hermione breathed. 'If she could have done
one thing to make
absolutely sure that every single person in this school
will read your interview, it was
banning it!'
---'Harry Potter and the order of the phoenix', P513
--
※ 发信站: 批踢踢实业坊(ptt.cc)
◆ From: 140.112.240.54
1F:推 march20:对, 总而言之, 就是 pointer 06/17 07:02