summaryrefslogtreecommitdiff
path: root/sys/compat
diff options
context:
space:
mode:
authorTed Unangst <tedu@cvs.openbsd.org>2014-01-21 01:49:14 +0000
committerTed Unangst <tedu@cvs.openbsd.org>2014-01-21 01:49:14 +0000
commitf90c52afe1afb9f8aa842f78b05b069e8eed0eaf (patch)
tree5726dedb4df2f891f73ebb42a2d59f2087f9cfb0 /sys/compat
parent179c2fc0580df2cd6c3014a61dea2927c704b39f (diff)
bzero -> memset
Diffstat (limited to 'sys/compat')
-rw-r--r--sys/compat/linux/linux_cdrom.c6
-rw-r--r--sys/compat/linux/linux_signal.c8
2 files changed, 7 insertions, 7 deletions
diff --git a/sys/compat/linux/linux_cdrom.c b/sys/compat/linux/linux_cdrom.c
index 38385553335..7c74d8d91b0 100644
--- a/sys/compat/linux/linux_cdrom.c
+++ b/sys/compat/linux/linux_cdrom.c
@@ -1,5 +1,5 @@
-/* $OpenBSD: linux_cdrom.c,v 1.9 2012/04/22 05:43:14 guenther Exp $ */
+/* $OpenBSD: linux_cdrom.c,v 1.10 2014/01/21 01:49:13 tedu Exp $ */
/*
* Copyright 1997 Niels Provos <provos@physnet.uni-hamburg.de>
* All rights reserved.
@@ -137,7 +137,7 @@ linux_ioctl_cdrom(p, v, retval)
sg = stackgap_init(p->p_emul);
- bzero(&tmpb.tes, sizeof tmpb.tes);
+ memset(&tmpb.tes, 0, sizeof tmpb.tes);
tmpb.tes.starting_track = tmpl.te.cdte_track;
tmpb.tes.address_format = (tmpl.te.cdte_format == LINUX_CDROM_MSF)
? CD_MSF_FORMAT : CD_LBA_FORMAT;
@@ -166,7 +166,7 @@ linux_ioctl_cdrom(p, v, retval)
sg = stackgap_init(p->p_emul);
- bzero(&tmpb.sc, sizeof tmpb.sc);
+ memset(&tmpb.sc, 0, sizeof tmpb.sc);
tmpb.sc.data_format = CD_CURRENT_POSITION;
tmpb.sc.address_format = (tmpl.sc.cdsc_format == LINUX_CDROM_MSF)
? CD_MSF_FORMAT : CD_LBA_FORMAT;
diff --git a/sys/compat/linux/linux_signal.c b/sys/compat/linux/linux_signal.c
index 67af421caef..af5666317f7 100644
--- a/sys/compat/linux/linux_signal.c
+++ b/sys/compat/linux/linux_signal.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: linux_signal.c,v 1.15 2012/06/19 11:35:29 pirofti Exp $ */
+/* $OpenBSD: linux_signal.c,v 1.16 2014/01/21 01:49:13 tedu Exp $ */
/* $NetBSD: linux_signal.c,v 1.10 1996/04/04 23:51:36 christos Exp $ */
/*
@@ -53,13 +53,13 @@
#include <compat/linux/linux_syscallargs.h>
#include <compat/linux/linux_util.h>
-#define sigemptyset(s) bzero((s), sizeof(*(s)))
+#define sigemptyset(s) memset((s), 0, sizeof(*(s)))
#define sigismember(s, n) (*(s) & sigmask(n))
#define sigaddset(s, n) (*(s) |= sigmask(n))
/* Locally used defines (in bsd<->linux conversion functions): */
#define linux_sigmask(n) (1 << ((n) - 1))
-#define linux_sigemptyset(s) bzero((s), sizeof(*(s)))
+#define linux_sigemptyset(s) memset((s), 0, sizeof(*(s)))
#define linux_sigismember(s, n) ((s)->sig[((n) - 1) / LINUX__NSIG_BPW] \
& (1 << ((n) - 1) % LINUX__NSIG_BPW))
#define linux_sigaddset(s, n) ((s)->sig[((n) - 1) / LINUX__NSIG_BPW] \
@@ -333,7 +333,7 @@ bsd_to_linux_sigaction(bsa, lsa)
{
/* Clear sa_flags and sa_restorer (if it exists) */
- bzero(lsa, sizeof(struct linux_sigaction));
+ memset(lsa, 0, sizeof(struct linux_sigaction));
/* ...and fill in the mask and flags */
bsd_to_linux_sigset(&bsa->sa_mask, &lsa->sa_mask);