|
Last change
on this file since 108 was 10, checked in by bird, 23 years ago |
|
Initial revision
|
-
Property cvs2svn:cvs-rev
set to
1.1
-
Property svn:eol-style
set to
native
-
Property svn:executable
set to
*
|
|
File size:
522 bytes
|
| Line | |
|---|
| 1 | /* Portable version of bzero for systems without it.
|
|---|
| 2 | This function is in the public domain. */
|
|---|
| 3 |
|
|---|
| 4 | /*
|
|---|
| 5 | NAME
|
|---|
| 6 | bzero -- zero the contents of a specified memory region
|
|---|
| 7 |
|
|---|
| 8 | SYNOPSIS
|
|---|
| 9 | void bzero (char *to, int count)
|
|---|
| 10 |
|
|---|
| 11 | DESCRIPTION
|
|---|
| 12 | Zero COUNT bytes of memory pointed to by TO.
|
|---|
| 13 |
|
|---|
| 14 | BUGS
|
|---|
| 15 | Significant speed enhancements may be made in some environments
|
|---|
| 16 | by zeroing more than a single byte at a time, or by unrolling the
|
|---|
| 17 | loop.
|
|---|
| 18 |
|
|---|
| 19 | */
|
|---|
| 20 |
|
|---|
| 21 |
|
|---|
| 22 | void
|
|---|
| 23 | bzero (to, count)
|
|---|
| 24 | char *to;
|
|---|
| 25 | int count;
|
|---|
| 26 | {
|
|---|
| 27 | while (count-- > 0)
|
|---|
| 28 | {
|
|---|
| 29 | *to++ = 0;
|
|---|
| 30 | }
|
|---|
| 31 | }
|
|---|
Note:
See
TracBrowser
for help on using the repository browser.