date and time created 85/08/05 21:43:15 by kre
authorRobert Elz <kre@ucbvax.Berkeley.EDU>
Tue, 6 Aug 1985 12:43:15 +0000 (04:43 -0800)
committerRobert Elz <kre@ucbvax.Berkeley.EDU>
Tue, 6 Aug 1985 12:43:15 +0000 (04:43 -0800)
SCCS-vsn: lib/libc/string/memset.c 5.1

usr/src/lib/libc/string/memset.c [new file with mode: 0644]

diff --git a/usr/src/lib/libc/string/memset.c b/usr/src/lib/libc/string/memset.c
new file mode 100644 (file)
index 0000000..331d755
--- /dev/null
@@ -0,0 +1,26 @@
+/*
+ * Copyright (c) 1985 Regents of the University of California.
+ * All rights reserved.  The Berkeley software License Agreement
+ * specifies the terms and conditions for redistribution.
+ */
+
+/*
+ * Sys5 compat routine
+ */
+
+#ifndef lint
+static char sccsid[] = "@(#)memset.c   5.1 (Berkeley) 85/08/05";
+#endif
+
+char *
+memset(s, c, n)
+       register char *s;
+       register c, n;
+{
+       register char *p = s;
+
+       while (--n >= 0)
+               *s++ = c;
+
+       return (p);
+}