Solved

Is new[] and delete[] compatibile with realloc() ?

Posted on 2002-04-10
1
230 Views
Last Modified: 2010-04-02
When dealing with char[] array, can I safely mix new and
delete operators with realloc(), or do I have to use
malloc() realloc() free() functions?
0
Comment
Question by:Robson
1 Comment
 
LVL 6

Accepted Solution

by:
thienpnguyen earned 100 total points
ID: 6930780
In C++, you can use new, delete, malloc, free, realloc together . However, the pointer that is related to "new" can not pass to realloc, free .. .
0

Featured Post

6 Surprising Benefits of Threat Intelligence

All sorts of threat intelligence is available on the web. Intelligence you can learn from, and use to anticipate and prepare for future attacks.

Join & Write a Comment

When writing generic code, using template meta-programming techniques, it is sometimes useful to know if a type is convertible to another type. A good example of when this might be is if you are writing diagnostic instrumentation for code to generat…
C++ Properties One feature missing from standard C++ that you will find in many other Object Oriented Programming languages is something called a Property (http://www.experts-exchange.com/Programming/Languages/CPP/A_3912-Object-Properties-in-C.ht…
The goal of the video will be to teach the user the difference and consequence of passing data by value vs passing data by reference in C++. An example of passing data by value as well as an example of passing data by reference will be be given. Bot…
The viewer will be introduced to the member functions push_back and pop_back of the vector class. The video will teach the difference between the two as well as how to use each one along with its functionality.

708 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

Need Help in Real-Time?

Connect with top rated Experts

12 Experts available now in Live!

Get 1:1 Help Now