BSD 4_3 release
[unix-history] / usr / src / lib / libc / compat-sys5 / memset.c
CommitLineData
63f04cd8
RE
1/*
2 * Copyright (c) 1985 Regents of the University of California.
3 * All rights reserved. The Berkeley software License Agreement
4 * specifies the terms and conditions for redistribution.
5 */
6
7/*
8 * Sys5 compat routine
9 */
10
2ce81398
DS
11#if defined(LIBC_SCCS) && !defined(lint)
12static char sccsid[] = "@(#)memset.c 5.2 (Berkeley) 86/03/09";
63f04cd8
RE
13#endif
14
15char *
16memset(s, c, n)
17 register char *s;
18 register c, n;
19{
20 register char *p = s;
21
22 while (--n >= 0)
23 *s++ = c;
24
25 return (p);
26}