scc

A fork of https://git.simple-cc.org/scc/ for Qute

git clone https://git.8pit.net/scc.git

 1#include <string.h>
 2
 3#undef strncat
 4
 5char *
 6strncat(char *restrict s1, const char *restrict s2, size_t n)
 7{
 8	char *ret;
 9
10	for (ret = s1; *s1; ++s1)
11		;
12	while (n-- > 0 && *s2)
13		*s1++ = *s2++;
14	*s1 = '\0';
15
16	return ret;
17}