天天看點

CRT detected that application wrote memory after end of heap buffer.

在程式的開始處我申請了一塊記憶體,中間對其進行了一些操作,在程式結束處,釋放記憶體的時候,引起錯誤:

HEAP CORRUPTION DETECTED:after Normal block(#***) at 0x****.CRT detected that application wrote memory after end of heap buffer.

錯誤原因:

以對内在操作的過程中,所寫的位址超出了,所配置設定内在的邊界

memcpy的時候,size參數比new出來的空間還大

繼續閱讀