Solved

DEBUG ERROR!

Posted on 2000-05-04
2
210 Views
Last Modified: 2010-04-02
Dear All,

 A DEBUG Error appears when I call a delete operation in my program, eg

delete video_decoder;

I checked that it had passed all the operations in the destructor however, it can't return to my main program.

In the debug error message, it shows:

DAMAGE: after Normal block (#28) at 0x00A40060.

Do you know the reason and any solution?

Thanks
0
Comment
Question by:littleboy
2 Comments
 

Expert Comment

by:forza
ID: 2779731
Can you post some code?
0
 
LVL 3

Accepted Solution

by:
LucHoltkamp earned 100 total points
ID: 2779782
I think you overwritten a piece of memory after or before the memory you allocated, somewhere you use an uninitialised pointer, or reference a piece of memory bejond the allocated range.
In DEBUG mode, MFC (if its VC) will allocate a small extra piece of memory before and after a block of memory that is allocated with new.
When the memory is deleted, it checks if you've overwritten that piece of memory, and if so, issues an assertion.
Luc
0

Featured Post

Free Tool: Port Scanner

Check which ports are open to the outside world. Helps make sure that your firewall rules are working as intended.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
PDF library for Delphi 2 128
What is sub-make ? 2 71
Beginner to Unreal Engine 4 5 94
DCT of  2D array using fftw in c++ 9 69
  Included as part of the C++ Standard Template Library (STL) is a collection of generic containers. Each of these containers serves a different purpose and has different pros and cons. It is often difficult to decide which container to use and …
Container Orchestration platforms empower organizations to scale their apps at an exceptional rate. This is the reason numerous innovation-driven companies are moving apps to an appropriated datacenter wide platform that empowers them to scale at a …
The viewer will learn how to use the return statement in functions in C++. The video will also teach the user how to pass data to a function and have the function return data back for further processing.
The viewer will be introduced to the technique of using vectors in C++. The video will cover how to define a vector, store values in the vector and retrieve data from the values stored in the vector.

828 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question