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...


What is the difference between realloc() and free()



What is the difference between realloc() and free()..

Answer / nitin

The free subroutine frees a block of memory previously
allocated by the malloc subroutine. Undefined results occur if
the Pointer parameter is not a valid pointer. If the Pointer
parameter is a null value, no action will occur. The realloc
subroutine changes the size of the block of memory pointed to
by the Pointer parameter to the number of bytes specified by
the Size parameter and returns a new pointer to the block. The
pointer specified by the Pointer parameter must have been
created with the malloc, calloc, or realloc subroutines and
not been deallocated with the free or realloc subroutines.
Undefined results occur if the Pointer parameter is not a
valid pointer.

Is This Answer Correct ?    3 Yes 0 No

Post New Answer

More C Interview Questions

to convert a string without using decrement operater and string functions

1 Answers  


is it possible to create your own header files?

0 Answers  


How does selection sort work in c?

0 Answers  


How can I do graphics in c?

0 Answers  


What is Dynamic Initialization.

3 Answers  


number of times a digit is present in a number

0 Answers  


Is a house a mass structure?

0 Answers  


What is structure packing in c?

0 Answers  


Can you assign a different address to an array tag?

0 Answers  


What is the purpose of clrscr () printf () and getch ()?

0 Answers  


progrem to generate the following series 1 12 123 1234 12345

6 Answers   HCL, Wipro,


We can draw a box in cprogram by using only one printf();& without using graphic.h header file?

4 Answers   NIIT,


Categories