Initial revision
This commit is contained in:
16
modules/src/string/strncat.c
Normal file
16
modules/src/string/strncat.c
Normal file
@@ -0,0 +1,16 @@
|
||||
/* append t to s, upto n characters
|
||||
*/
|
||||
char *
|
||||
strncat(s, t, n)
|
||||
register char *s, *t;
|
||||
register int n;
|
||||
{
|
||||
register char *b = s;
|
||||
|
||||
while (*s++)
|
||||
;
|
||||
s--;
|
||||
while ((n-- > 0) && (*s++ = *t++))
|
||||
;
|
||||
return b;
|
||||
}
|
||||
Reference in New Issue
Block a user