BOOTSTRAP (kutils) functions


LIBRARY ROUTINE

krealloc - re-allocate a piece of memory to a new size

LIBRARY CALL

kaddr krealloc(
   kaddr  ptr,
   size_t size)

INPUT

OUTPUT

none

RETURN VALUE

The address of the allocated memory. NULL is returned if the allocation fails, or if size is 0. If ptr is NULL, malloc will be called instead of realloc.

DESCRIPTION

The macro calls realloc() to re-allocate the block of memory with size bytes. The realloc will automatically copy the data from the first memory block to the newly allocated one.

ADDITIONAL INFORMATION

none

EXAMPLES

none

SIDE EFFECTS

none

RESTRICTIONS

none

MODIFICATION

none

FILES

$BOOTSTRAP/objects/library/kutils/src/memory.c

SEE ALSO

kutils(3)

COPYRIGHT

Copyright (C) 1993 - 1997, Khoral Research, Inc. ("KRI") All rights reserved.