Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

When you call malloc() to allocate memory for a local
pointer, do you have to explicitly free() it?

Answer Posted / shruti

yup.. we have to explicitly free it..
otherwise it results in "dangling pointer"..

Is This Answer Correct ?    20 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

This is a variation of the call_me function in the previous question:call_me (myvar)int *myvar;{ *myvar += 5; }The correct way to call this function from main() will be a) call_me(myvar) b) call_me(*myvar) c) call_me(&myvar) d) expanded memory

1339


What is the difference between arrays and pointers?

1174


what is use of malloc and calloc?

1952


Given two strings S1 and S2. Delete from S2 all those characters which occur in S1 also and finally create a clean S2 with the relevant characters deleted.

1472


What is a list in c?

1083


Write a C/C++ program that connects to a MySQL server and checks if the InnoDB plug-in is installed on it. If so, your program should print the maximum number of concurrent threads that the InnoDB plug-in can create.

1999


What is the size of empty structure in c?

1127


What is the difference between typedef and #define?

1112


hi any body pls give me company name interview conduct "c" language only

2323


What is the main difference between calloc () and malloc ()?

1233


Is there a way to switch on strings?

1128


Write a program, where i have a grid with many cells, how many paths are possible from one point to other desired points.

1293


Can I initialize unions?

1090


why wipro wase

2367


Differentiate between static and dynamic modeling.

1186