Define memory leak?, C/C++ Programming

A: Memory that has no pointer pointing to it and there is no method to delete or reuse this memory(object), it causes Memory leak.

{

Base *b = new base();

}

Out of this scope b no longer present, however the memory it was pointing to was not deleted. Pointer b itself was destroyed while it went out of scope.

 

Posted Date: 3/19/2013 8:57:08 AM | Location : United States







Related Discussions:- Define memory leak?, Assignment Help, Ask Question on Define memory leak?, Get Answer, Expert's Help, Define memory leak? Discussions

Write discussion on Define memory leak?
Your posts are moderated
Related Questions
Program to find a Greatest String: C - Program: Write a program find largest string by c program. int main( int argc, char *argv[] ) {     if( argc         {

write a program to find area of curve y=f(x) between x and x=b,integrate between the limits a and b using c     #include float start_point, /* GL

Question 1. Explain Briefly about class and objects. 2. Create a class string which stores a string value. Overload ++ operator which converts the characters of the string t

for object, malloc allocates memory in heap however doesn't invoke object's constructor to initialize the object. new allocates memory & also invokes constructor to initialize the

need some help with finishing a program

Using a Friend Using a friend function is quite easy. The following example explains a friend function to access members of two classes. class Bclass;

How to insert values in array - c++ program: Write a program to insert values in array void main() { int a[2][3][2]={                                 {

Project Description: P2P media streaming browser (IE, Chrome, Firefox) plug-in needed that is compatible with Win Xp,7,8 that is Windows Firewall friendly Example like Swarm

Destructors A destructor function gets implemented whenever an instance of the class to which it belongs goes out of existence. The primary usage of a destructor function is

define a class for student