Crossware

Table of Contents        Previous topic       Next topic       

C COMPILER LIBRARY FUNCTION REFERENCE->Detailed Descriptions->strncat()

Summary

#include <string.h>

    
char *strncat(char* string1, const char* string2, size_t n);Append one string to another

Parameters

    
string1String to be extended
string2String to be appended
nNumber of characters to be appended


Description

This function appends (concatenates), at most, n characters from string2 onto the tail of string1 to form an extended string string1.  If n is greater than the length of string2 then the length of string2 is used instead.

Both string1 and string2 must be null terminated strings and the resulting string1 is null terminated.


Return Value

The pointer to string1 is returned.