HEAP: Free Heap block 314668 modified at 314808 after it was freed

Started by
3 comments, last by Sand_Hawk 21 years, 3 months ago
During runtime I get this error on my debug screen: HEAP: Free Heap block 314668 modified at 314808 after it was freed. It doens''t crash my program, however, it seems like it isn''t very good. I traced that the error occurs when I do a delete [] ccClientData. I am using threads and I am making sure all the threads are ended. The CClient class doesn''t have ANY pointers wich need to be deleted, just normal variables. What does this error to be caused? Sand Hawk ---------------- -Earth is 98% full. Please delete anybody you can.
My Site
----------------(Inspired by Pouya)
Advertisement
seems like you''re freeing memory twice.
The heap is used for pointer right? So in this case I am double deleting a pointer. Let the hunting begin...

Sand Hawk

----------------
-Earth is 98% full. Please delete anybody you can.


My Site
----------------(Inspired by Pouya)
To me, it seems like you''re modifying already freed memory. Double freeing results in a different message, I think.

I found the error. When I created the memory, I ussed the wrong variable, creating 1 place too short. During runtime, I was accessing this memory though. I fixed up the code and the problem is solved now. (Thanks to some help from Pouya)

Sand Hawk

----------------
-Earth is 98% full. Please delete anybody you can.


My Site
----------------(Inspired by Pouya)

This topic is closed to new replies.

Advertisement