My application (c++) uses both new and malloc() for dynamic memory allocation. In some cases, however, it seems that new allocates the same memory twice. The two pointers, which should point to different memory areas and which both are allocated using new, do not depend on each other in any way, but their numerical value after the allocation simply is the same. The problem has not occurred in small programs, but I have encountered it twice when making medium-size programs. Due to the size of the program, I can't include an example.