home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
The C Users' Group Library 1994 August
/
wc-cdrom-cusersgrouplibrary-1994-08.iso
/
vol_100
/
163_02
/
strncat.c
< prev
next >
Wrap
Text File
|
1988-01-31
|
384b
|
11 lines
/*
** append s2 to s1, truncating at n characters if necessary
*/
strncat(s1, s2, n) char *s1, *s2; int n; {
char *strncat;
strncat = s1;
while(*s1) s1++;
while(n--) if(!(*s1++ = *s2++)) break;
return strncat;
}