Copies a memory block.
void * memccpy (void * dest, void * source, int c, size_t length);
Required Header |
<string.h> |
Return Value
This function returns a pointer to the character after c, if c was a copied character, or NULL otherwise.
Parameters
dest
The destination memory block
source
The source memory block
c
The character that stops the copy process
length
The length of the memory blocks
Remarks
The memccpy function copies at most length bytes from source to dest, stopping when character c has been copied in which case the return value is the position following that character in the destination buffer.
See Also bcopy, memchr, memcmp, memcpy, _memicmp, memmove, memset, strcpy, strncpy