strcat.c revision 1817
199005Sobrien/*
299005Sobrien * Copyright (c) 1988, 1993
399005Sobrien *	The Regents of the University of California.  All rights reserved.
499005Sobrien *
599005Sobrien * Redistribution and use in source and binary forms, with or without
699005Sobrien * modification, are permitted provided that the following conditions
799005Sobrien * are met:
899005Sobrien * 1. Redistributions of source code must retain the above copyright
999005Sobrien *    notice, this list of conditions and the following disclaimer.
1099005Sobrien * 2. Redistributions in binary form must reproduce the above copyright
1199005Sobrien *    notice, this list of conditions and the following disclaimer in the
1299005Sobrien *    documentation and/or other materials provided with the distribution.
1399005Sobrien * 3. All advertising materials mentioning features or use of this software
1499005Sobrien *    must display the following acknowledgement:
1599005Sobrien *	This product includes software developed by the University of
1699005Sobrien *	California, Berkeley and its contributors.
1799005Sobrien * 4. Neither the name of the University nor the names of its contributors
1899005Sobrien *    may be used to endorse or promote products derived from this software
1999005Sobrien *    without specific prior written permission.
2099005Sobrien *
2199005Sobrien * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
2299005Sobrien * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
2399005Sobrien * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
2499005Sobrien * ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
2599005Sobrien * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
26 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
27 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
28 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
29 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
30 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
31 * SUCH DAMAGE.
32 *
33 * $Id$
34 */
35
36#include <string.h>
37
38char *
39strcat(s, append)
40	register char *s;
41	register const char *append;
42{
43	char *save = s;
44
45	for (; *s; ++s);
46	while (*s++ = *append++);
47	return(save);
48}
49