summaryrefslogtreecommitdiff
path: root/libc/sysdeps/linux
diff options
context:
space:
mode:
authorEric Andersen <andersen@codepoet.org>2004-03-18 11:28:51 +0000
committerEric Andersen <andersen@codepoet.org>2004-03-18 11:28:51 +0000
commitada7878ba0d097b798277aaa095e9d935a64fa99 (patch)
tree1d202eb0bb53ff5167d8ab91ac90e48034920438 /libc/sysdeps/linux
parent0c91a787b60e3a8804c1001724b039a0b80c7bb4 (diff)
Based on a patch from Alexandre Oliva, remove all reference to 'bzero' (which
is not a SuSv3 symbol). Rather than using __bzero internally per Alexandre's original patch, use memset instead.
Diffstat (limited to 'libc/sysdeps/linux')
-rw-r--r--libc/sysdeps/linux/common/poll.c24
1 files changed, 12 insertions, 12 deletions
diff --git a/libc/sysdeps/linux/common/poll.c b/libc/sysdeps/linux/common/poll.c
index 3c26a4933..06c857c43 100644
--- a/libc/sysdeps/linux/common/poll.c
+++ b/libc/sysdeps/linux/common/poll.c
@@ -62,9 +62,9 @@ int poll(struct pollfd *fds, nfds_t nfds, int timeout)
/* We can't call FD_ZERO, since FD_ZERO only works with sets
of exactly __FD_SETSIZE size. */
- bzero (rset, bytes);
- bzero (wset, bytes);
- bzero (xset, bytes);
+ memset (rset, 0, bytes);
+ memset (wset, 0, bytes);
+ memset (xset, 0, bytes);
for (f = fds; f < &fds[nfds]; ++f)
{
@@ -86,9 +86,9 @@ int poll(struct pollfd *fds, nfds_t nfds, int timeout)
nwset = alloca (nbytes);
nxset = alloca (nbytes);
- bzero ((char *) nrset + bytes, nbytes - bytes);
- bzero ((char *) nwset + bytes, nbytes - bytes);
- bzero ((char *) nxset + bytes, nbytes - bytes);
+ memset ((char *) nrset + bytes, 0, nbytes - bytes);
+ memset ((char *) nwset + bytes, 0, nbytes - bytes);
+ memset ((char *) nxset + bytes, 0, nbytes - bytes);
rset = memcpy (nrset, rset, bytes);
wset = memcpy (nwset, wset, bytes);
@@ -126,9 +126,9 @@ int poll(struct pollfd *fds, nfds_t nfds, int timeout)
struct timeval sngl_tv;
/* Clear the original set. */
- bzero (rset, bytes);
- bzero (wset, bytes);
- bzero (xset, bytes);
+ memset (rset, 0, bytes);
+ memset (wset, 0, bytes);
+ memset (xset, 0, bytes);
/* This means we don't wait for input. */
sngl_tv.tv_sec = 0;
@@ -145,9 +145,9 @@ int poll(struct pollfd *fds, nfds_t nfds, int timeout)
{
int n;
- bzero (sngl_rset, bytes);
- bzero (sngl_wset, bytes);
- bzero (sngl_xset, bytes);
+ memset (sngl_rset, 0, bytes);
+ memset (sngl_wset, 0, bytes);
+ memset (sngl_xset, 0, bytes);
if (f->events & POLLIN)
FD_SET (f->fd, sngl_rset);